Skip to content

Latest commit

 

History

History
409 lines (325 loc) · 14.8 KB

OrganizationsApi.md

File metadata and controls

409 lines (325 loc) · 14.8 KB

Org.OpenAPITools.Api.OrganizationsApi

All URIs are relative to https://api.teke.li/api/v1/obs

Method HTTP request Description
GetorganizationsItem GET /orgs/{organizationsId} Retrieves a organizations document
Getorgs GET /orgs Retrieves one or more orgs
PatchorganizationsItem PATCH /orgs/{organizationsId} Updates a organizations document
Postorgs POST /orgs Stores one or more orgs.
PutorganizationsItem PUT /orgs/{organizationsId} Replaces a organizations document

GetorganizationsItem

Organizations GetorganizationsItem (string organizationsId)

Retrieves a organizations document

Example

using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class GetorganizationsItemExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://api.teke.li/api/v1/obs";
            // Configure API key authorization: ApiKeyHeaderAuth
            Configuration.Default.AddApiKey("X-Api-Key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("X-Api-Key", "Bearer");
            // Configure API key authorization: ApiKeyQueryAuth
            Configuration.Default.AddApiKey("api_key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("api_key", "Bearer");

            var apiInstance = new OrganizationsApi(Configuration.Default);
            var organizationsId = organizationsId_example;  // string | 

            try
            {
                // Retrieves a organizations document
                Organizations result = apiInstance.GetorganizationsItem(organizationsId);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling OrganizationsApi.GetorganizationsItem: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
organizationsId string

Return type

Organizations

Authorization

ApiKeyHeaderAuth, ApiKeyQueryAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 organizations document fetched successfully -
0 An error message -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Getorgs

InlineResponse2008 Getorgs (string where = null, string sort = null, int? page = null, int? maxResults = null)

Retrieves one or more orgs

Example

using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class GetorgsExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://api.teke.li/api/v1/obs";
            // Configure API key authorization: ApiKeyHeaderAuth
            Configuration.Default.AddApiKey("X-Api-Key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("X-Api-Key", "Bearer");
            // Configure API key authorization: ApiKeyQueryAuth
            Configuration.Default.AddApiKey("api_key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("api_key", "Bearer");

            var apiInstance = new OrganizationsApi(Configuration.Default);
            var where = where_example;  // string | the filters query parameter (ex.: {\"number\": 10}) (optional) 
            var sort = sort_example;  // string | the sort query parameter (ex.: \"city,-lastname\") (optional) 
            var page = 1;  // int? | the pages query parameter (optional) 
            var maxResults = 25;  // int? | the max results query parameter (optional) 

            try
            {
                // Retrieves one or more orgs
                InlineResponse2008 result = apiInstance.Getorgs(where, sort, page, maxResults);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling OrganizationsApi.Getorgs: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
where string the filters query parameter (ex.: {"number": 10}) [optional]
sort string the sort query parameter (ex.: "city,-lastname") [optional]
page int? the pages query parameter [optional]
maxResults int? the max results query parameter [optional]

Return type

InlineResponse2008

Authorization

ApiKeyHeaderAuth, ApiKeyQueryAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 An array of orgs -
0 An error message -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

PatchorganizationsItem

void PatchorganizationsItem (string organizationsId, string ifMatch, Organizations organizations)

Updates a organizations document

Example

using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class PatchorganizationsItemExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://api.teke.li/api/v1/obs";
            // Configure API key authorization: ApiKeyHeaderAuth
            Configuration.Default.AddApiKey("X-Api-Key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("X-Api-Key", "Bearer");
            // Configure API key authorization: ApiKeyQueryAuth
            Configuration.Default.AddApiKey("api_key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("api_key", "Bearer");

            var apiInstance = new OrganizationsApi(Configuration.Default);
            var organizationsId = organizationsId_example;  // string | 
            var ifMatch = ifMatch_example;  // string | Current value of the _etag field
            var organizations = new Organizations(); // Organizations | A organizations or list of organizations documents

            try
            {
                // Updates a organizations document
                apiInstance.PatchorganizationsItem(organizationsId, ifMatch, organizations);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling OrganizationsApi.PatchorganizationsItem: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
organizationsId string
ifMatch string Current value of the _etag field
organizations Organizations A organizations or list of organizations documents

Return type

void (empty response body)

Authorization

ApiKeyHeaderAuth, ApiKeyQueryAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 organizations document updated successfully -
0 An error message -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Postorgs

void Postorgs (Organizations organizations)

Stores one or more orgs.

Example

using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class PostorgsExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://api.teke.li/api/v1/obs";
            // Configure API key authorization: ApiKeyHeaderAuth
            Configuration.Default.AddApiKey("X-Api-Key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("X-Api-Key", "Bearer");
            // Configure API key authorization: ApiKeyQueryAuth
            Configuration.Default.AddApiKey("api_key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("api_key", "Bearer");

            var apiInstance = new OrganizationsApi(Configuration.Default);
            var organizations = new Organizations(); // Organizations | A organizations or list of organizations documents

            try
            {
                // Stores one or more orgs.
                apiInstance.Postorgs(organizations);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling OrganizationsApi.Postorgs: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
organizations Organizations A organizations or list of organizations documents

Return type

void (empty response body)

Authorization

ApiKeyHeaderAuth, ApiKeyQueryAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
201 operation has been successful -
0 An error message -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

PutorganizationsItem

void PutorganizationsItem (string organizationsId, string ifMatch, Organizations organizations)

Replaces a organizations document

Example

using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;

namespace Example
{
    public class PutorganizationsItemExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://api.teke.li/api/v1/obs";
            // Configure API key authorization: ApiKeyHeaderAuth
            Configuration.Default.AddApiKey("X-Api-Key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("X-Api-Key", "Bearer");
            // Configure API key authorization: ApiKeyQueryAuth
            Configuration.Default.AddApiKey("api_key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("api_key", "Bearer");

            var apiInstance = new OrganizationsApi(Configuration.Default);
            var organizationsId = organizationsId_example;  // string | 
            var ifMatch = ifMatch_example;  // string | Current value of the _etag field
            var organizations = new Organizations(); // Organizations | A organizations or list of organizations documents

            try
            {
                // Replaces a organizations document
                apiInstance.PutorganizationsItem(organizationsId, ifMatch, organizations);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling OrganizationsApi.PutorganizationsItem: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
organizationsId string
ifMatch string Current value of the _etag field
organizations Organizations A organizations or list of organizations documents

Return type

void (empty response body)

Authorization

ApiKeyHeaderAuth, ApiKeyQueryAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 organizations document replaced successfully -
0 An error message -

[Back to top] [Back to API list] [Back to Model list] [Back to README]