All URIs are relative to https://api.getlago.com/api/v1
Method | HTTP request | Description |
---|---|---|
CreateCreditNote | POST /credit_notes | Create a new Credit note |
DownloadCreditNote | POST /credit_notes/{id}/download | Download an existing credit note |
FindAllCreditNotes | GET /credit_notes | Find Credit notes |
FindCreditNote | GET /credit_notes/{id} | Find credit note |
UpdateCreditNote | PUT /credit_notes/{id} | Update an existing credit note |
VoidCreditNote | PUT /credit_notes/{id}/void | Void existing credit note |
CreditNote CreateCreditNote (CreditNoteInput creditNoteInput)
Create a new Credit note
Create a new credit note
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class CreateCreditNoteExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.getlago.com/api/v1";
// Configure Bearer token for authorization: bearerAuth
config.AccessToken = "YOUR_BEARER_TOKEN";
var apiInstance = new CreditNotesApi(config);
var creditNoteInput = new CreditNoteInput(); // CreditNoteInput | Credit note payload
try
{
// Create a new Credit note
CreditNote result = apiInstance.CreateCreditNote(creditNoteInput);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CreditNotesApi.CreateCreditNote: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// Create a new Credit note
ApiResponse<CreditNote> response = apiInstance.CreateCreditNoteWithHttpInfo(creditNoteInput);
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 CreditNotesApi.CreateCreditNoteWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
creditNoteInput | CreditNoteInput | Credit note payload |
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Successful response | - |
400 | Bad Request error | - |
401 | Unauthorized error | - |
422 | Unprocessable entity error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
CreditNote DownloadCreditNote (Guid id)
Download an existing credit note
Download an existing credit note
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class DownloadCreditNoteExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.getlago.com/api/v1";
// Configure Bearer token for authorization: bearerAuth
config.AccessToken = "YOUR_BEARER_TOKEN";
var apiInstance = new CreditNotesApi(config);
var id = 1a901a90-1a90-1a90-1a90-1a901a901a90; // Guid | ID of the existing Lago Credit note
try
{
// Download an existing credit note
CreditNote result = apiInstance.DownloadCreditNote(id);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CreditNotesApi.DownloadCreditNote: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// Download an existing credit note
ApiResponse<CreditNote> response = apiInstance.DownloadCreditNoteWithHttpInfo(id);
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 CreditNotesApi.DownloadCreditNoteWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
id | Guid | ID of the existing Lago Credit note |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Successful response | - |
401 | Unauthorized error | - |
404 | Not Found error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
CreditNotes FindAllCreditNotes (int? page = null, int? perPage = null, string externalCustomerId = null)
Find Credit notes
Find all credit notes in certain organisation
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class FindAllCreditNotesExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.getlago.com/api/v1";
// Configure Bearer token for authorization: bearerAuth
config.AccessToken = "YOUR_BEARER_TOKEN";
var apiInstance = new CreditNotesApi(config);
var page = 2; // int? | Number of page (optional)
var perPage = 20; // int? | Number of records per page (optional)
var externalCustomerId = 12345; // string | External customer ID (optional)
try
{
// Find Credit notes
CreditNotes result = apiInstance.FindAllCreditNotes(page, perPage, externalCustomerId);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CreditNotesApi.FindAllCreditNotes: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// Find Credit notes
ApiResponse<CreditNotes> response = apiInstance.FindAllCreditNotesWithHttpInfo(page, perPage, externalCustomerId);
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 CreditNotesApi.FindAllCreditNotesWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
page | int? | Number of page | [optional] |
perPage | int? | Number of records per page | [optional] |
externalCustomerId | string | External customer ID | [optional] |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Successful response | - |
401 | Unauthorized error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
CreditNote FindCreditNote (string id)
Find credit note
Return a single credit note
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class FindCreditNoteExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.getlago.com/api/v1";
// Configure Bearer token for authorization: bearerAuth
config.AccessToken = "YOUR_BEARER_TOKEN";
var apiInstance = new CreditNotesApi(config);
var id = 12345; // string | Id of the existing credit note
try
{
// Find credit note
CreditNote result = apiInstance.FindCreditNote(id);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CreditNotesApi.FindCreditNote: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// Find credit note
ApiResponse<CreditNote> response = apiInstance.FindCreditNoteWithHttpInfo(id);
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 CreditNotesApi.FindCreditNoteWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
id | string | Id of the existing credit note |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Successful response | - |
401 | Unauthorized error | - |
404 | Not Found error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
CreditNote UpdateCreditNote (string id, CreditNoteUpdateInput creditNoteUpdateInput)
Update an existing credit note
Update an existing credit note
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class UpdateCreditNoteExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.getlago.com/api/v1";
// Configure Bearer token for authorization: bearerAuth
config.AccessToken = "YOUR_BEARER_TOKEN";
var apiInstance = new CreditNotesApi(config);
var id = 12345; // string | Id of the existing credit note
var creditNoteUpdateInput = new CreditNoteUpdateInput(); // CreditNoteUpdateInput | Update an existing credit note
try
{
// Update an existing credit note
CreditNote result = apiInstance.UpdateCreditNote(id, creditNoteUpdateInput);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CreditNotesApi.UpdateCreditNote: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// Update an existing credit note
ApiResponse<CreditNote> response = apiInstance.UpdateCreditNoteWithHttpInfo(id, creditNoteUpdateInput);
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 CreditNotesApi.UpdateCreditNoteWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
id | string | Id of the existing credit note | |
creditNoteUpdateInput | CreditNoteUpdateInput | Update an existing credit note |
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Successful response | - |
400 | Bad Request error | - |
401 | Unauthorized error | - |
404 | Not Found error | - |
422 | Unprocessable entity error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
CreditNote VoidCreditNote (Guid id)
Void existing credit note
Void an existing credit note
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class VoidCreditNoteExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.getlago.com/api/v1";
// Configure Bearer token for authorization: bearerAuth
config.AccessToken = "YOUR_BEARER_TOKEN";
var apiInstance = new CreditNotesApi(config);
var id = 1a901a90-1a90-1a90-1a90-1a901a901a90; // Guid | ID of the existing Lago Credit note
try
{
// Void existing credit note
CreditNote result = apiInstance.VoidCreditNote(id);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CreditNotesApi.VoidCreditNote: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// Void existing credit note
ApiResponse<CreditNote> response = apiInstance.VoidCreditNoteWithHttpInfo(id);
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 CreditNotesApi.VoidCreditNoteWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
id | Guid | ID of the existing Lago Credit note |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Successful response | - |
401 | Unauthorized error | - |
404 | Not Found error | - |
405 | Not Allowed error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]