Skip to content

Latest commit

 

History

History
396 lines (306 loc) · 14.1 KB

WebhooksApi.md

File metadata and controls

396 lines (306 loc) · 14.1 KB

CIN7.DearInventory.Api.WebhooksApi

All URIs are relative to https://inventory.dearsystems.com/ExternalApi/v2

Method HTTP request Description
WebhooksGet GET /webhooks GET
WebhooksIdDelete DELETE /webhooks?ID={ID} Delete
WebhooksPost POST /webhooks POST
WebhooksPut PUT /webhooks PUT

WebhooksGet

WebhooksGet200Response WebhooksGet (string? apiAuthAccountid = null, string? apiAuthApplicationkey = null)

GET

Example

using System.Collections.Generic;
using System.Diagnostics;
using CIN7.DearInventory.Api;
using CIN7.DearInventory.Client;
using CIN7.DearInventory.Model;

namespace Example
{
    public class WebhooksGetExample
    {
        public static void Main()
        {
            Configuration config = new Configuration();
            config.BasePath = "https://inventory.dearsystems.com/ExternalApi/v2";
            var apiInstance = new WebhooksApi(config);
            var apiAuthAccountid = 704ef231-cd93-49c9-a201-26b4b5d0d35b;  // string? | e.g. 704ef231-cd93-49c9-a201-26b4b5d0d35b (optional)
            var apiAuthApplicationkey = 0342a546-e0c2-0dff-f0be-6a5e17154033;  // string? | e.g. 0342a546-e0c2-0dff-f0be-6a5e17154033 (optional)

            try
            {
                // GET
                WebhooksGet200Response result = apiInstance.WebhooksGet(apiAuthAccountid, apiAuthApplicationkey);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling WebhooksApi.WebhooksGet: " + e.Message);
                Debug.Print("Status Code: " + e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Using the WebhooksGetWithHttpInfo variant

This returns an ApiResponse object which contains the response data, status code and headers.

try
{
    // GET
    ApiResponse<WebhooksGet200Response> response = apiInstance.WebhooksGetWithHttpInfo(apiAuthAccountid, apiAuthApplicationkey);
    Debug.Write("Status Code: " + response.StatusCode);
    Debug.Write("Response Headers: " + response.Headers);
    Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
    Debug.Print("Exception when calling WebhooksApi.WebhooksGetWithHttpInfo: " + e.Message);
    Debug.Print("Status Code: " + e.ErrorCode);
    Debug.Print(e.StackTrace);
}

Parameters

Name Type Description Notes
apiAuthAccountid string? e.g. 704ef231-cd93-49c9-a201-26b4b5d0d35b [optional]
apiAuthApplicationkey string? e.g. 0342a546-e0c2-0dff-f0be-6a5e17154033 [optional]

Return type

WebhooksGet200Response

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 OK -

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

WebhooksIdDelete

WebhooksIdDelete200Response WebhooksIdDelete (string ID, string? apiAuthAccountid = null, string? apiAuthApplicationkey = null)

Delete

Example

using System.Collections.Generic;
using System.Diagnostics;
using CIN7.DearInventory.Api;
using CIN7.DearInventory.Client;
using CIN7.DearInventory.Model;

namespace Example
{
    public class WebhooksIdDeleteExample
    {
        public static void Main()
        {
            Configuration config = new Configuration();
            config.BasePath = "https://inventory.dearsystems.com/ExternalApi/v2";
            var apiInstance = new WebhooksApi(config);
            var ID = "ID_example";  // string | ID of Webhook to Delete.
            var apiAuthAccountid = 704ef231-cd93-49c9-a201-26b4b5d0d35b;  // string? | e.g. 704ef231-cd93-49c9-a201-26b4b5d0d35b (optional)
            var apiAuthApplicationkey = 0342a546-e0c2-0dff-f0be-6a5e17154033;  // string? | e.g. 0342a546-e0c2-0dff-f0be-6a5e17154033 (optional)

            try
            {
                // Delete
                WebhooksIdDelete200Response result = apiInstance.WebhooksIdDelete(ID, apiAuthAccountid, apiAuthApplicationkey);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling WebhooksApi.WebhooksIdDelete: " + e.Message);
                Debug.Print("Status Code: " + e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Using the WebhooksIdDeleteWithHttpInfo variant

This returns an ApiResponse object which contains the response data, status code and headers.

try
{
    // Delete
    ApiResponse<WebhooksIdDelete200Response> response = apiInstance.WebhooksIdDeleteWithHttpInfo(ID, apiAuthAccountid, apiAuthApplicationkey);
    Debug.Write("Status Code: " + response.StatusCode);
    Debug.Write("Response Headers: " + response.Headers);
    Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
    Debug.Print("Exception when calling WebhooksApi.WebhooksIdDeleteWithHttpInfo: " + e.Message);
    Debug.Print("Status Code: " + e.ErrorCode);
    Debug.Print(e.StackTrace);
}

Parameters

Name Type Description Notes
ID string ID of Webhook to Delete.
apiAuthAccountid string? e.g. 704ef231-cd93-49c9-a201-26b4b5d0d35b [optional]
apiAuthApplicationkey string? e.g. 0342a546-e0c2-0dff-f0be-6a5e17154033 [optional]

Return type

WebhooksIdDelete200Response

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 OK -

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

WebhooksPost

WebhooksPost200Response WebhooksPost (string? apiAuthAccountid = null, string? apiAuthApplicationkey = null, WebhooksPostRequest? webhooksPostRequest = null)

POST

Example

using System.Collections.Generic;
using System.Diagnostics;
using CIN7.DearInventory.Api;
using CIN7.DearInventory.Client;
using CIN7.DearInventory.Model;

namespace Example
{
    public class WebhooksPostExample
    {
        public static void Main()
        {
            Configuration config = new Configuration();
            config.BasePath = "https://inventory.dearsystems.com/ExternalApi/v2";
            var apiInstance = new WebhooksApi(config);
            var apiAuthAccountid = 704ef231-cd93-49c9-a201-26b4b5d0d35b;  // string? | e.g. 704ef231-cd93-49c9-a201-26b4b5d0d35b (optional)
            var apiAuthApplicationkey = 0342a546-e0c2-0dff-f0be-6a5e17154033;  // string? | e.g. 0342a546-e0c2-0dff-f0be-6a5e17154033 (optional)
            var webhooksPostRequest = new WebhooksPostRequest?(); // WebhooksPostRequest? |  (optional)

            try
            {
                // POST
                WebhooksPost200Response result = apiInstance.WebhooksPost(apiAuthAccountid, apiAuthApplicationkey, webhooksPostRequest);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling WebhooksApi.WebhooksPost: " + e.Message);
                Debug.Print("Status Code: " + e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Using the WebhooksPostWithHttpInfo variant

This returns an ApiResponse object which contains the response data, status code and headers.

try
{
    // POST
    ApiResponse<WebhooksPost200Response> response = apiInstance.WebhooksPostWithHttpInfo(apiAuthAccountid, apiAuthApplicationkey, webhooksPostRequest);
    Debug.Write("Status Code: " + response.StatusCode);
    Debug.Write("Response Headers: " + response.Headers);
    Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
    Debug.Print("Exception when calling WebhooksApi.WebhooksPostWithHttpInfo: " + e.Message);
    Debug.Print("Status Code: " + e.ErrorCode);
    Debug.Print(e.StackTrace);
}

Parameters

Name Type Description Notes
apiAuthAccountid string? e.g. 704ef231-cd93-49c9-a201-26b4b5d0d35b [optional]
apiAuthApplicationkey string? e.g. 0342a546-e0c2-0dff-f0be-6a5e17154033 [optional]
webhooksPostRequest WebhooksPostRequest? [optional]

Return type

WebhooksPost200Response

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 OK -

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

WebhooksPut

WebhooksPut200Response WebhooksPut (string? apiAuthAccountid = null, string? apiAuthApplicationkey = null, WebhooksPutRequest? webhooksPutRequest = null)

PUT

Example

using System.Collections.Generic;
using System.Diagnostics;
using CIN7.DearInventory.Api;
using CIN7.DearInventory.Client;
using CIN7.DearInventory.Model;

namespace Example
{
    public class WebhooksPutExample
    {
        public static void Main()
        {
            Configuration config = new Configuration();
            config.BasePath = "https://inventory.dearsystems.com/ExternalApi/v2";
            var apiInstance = new WebhooksApi(config);
            var apiAuthAccountid = 704ef231-cd93-49c9-a201-26b4b5d0d35b;  // string? | e.g. 704ef231-cd93-49c9-a201-26b4b5d0d35b (optional)
            var apiAuthApplicationkey = 0342a546-e0c2-0dff-f0be-6a5e17154033;  // string? | e.g. 0342a546-e0c2-0dff-f0be-6a5e17154033 (optional)
            var webhooksPutRequest = new WebhooksPutRequest?(); // WebhooksPutRequest? |  (optional)

            try
            {
                // PUT
                WebhooksPut200Response result = apiInstance.WebhooksPut(apiAuthAccountid, apiAuthApplicationkey, webhooksPutRequest);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling WebhooksApi.WebhooksPut: " + e.Message);
                Debug.Print("Status Code: " + e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Using the WebhooksPutWithHttpInfo variant

This returns an ApiResponse object which contains the response data, status code and headers.

try
{
    // PUT
    ApiResponse<WebhooksPut200Response> response = apiInstance.WebhooksPutWithHttpInfo(apiAuthAccountid, apiAuthApplicationkey, webhooksPutRequest);
    Debug.Write("Status Code: " + response.StatusCode);
    Debug.Write("Response Headers: " + response.Headers);
    Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
    Debug.Print("Exception when calling WebhooksApi.WebhooksPutWithHttpInfo: " + e.Message);
    Debug.Print("Status Code: " + e.ErrorCode);
    Debug.Print(e.StackTrace);
}

Parameters

Name Type Description Notes
apiAuthAccountid string? e.g. 704ef231-cd93-49c9-a201-26b4b5d0d35b [optional]
apiAuthApplicationkey string? e.g. 0342a546-e0c2-0dff-f0be-6a5e17154033 [optional]
webhooksPutRequest WebhooksPutRequest? [optional]

Return type

WebhooksPut200Response

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 OK -

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