Skip to content

Latest commit

 

History

History
820 lines (616 loc) · 29 KB

TaxInvoiceApi.md

File metadata and controls

820 lines (616 loc) · 29 KB

Flowaccount.OpenAPITools.Api.TaxInvoiceApi

All URIs are relative to https://openapi.flowaccount.com/v1

Method HTTP request Description
TaxInvoicesEmailDocumentPost POST /tax-invoices/email-document Send Email tax invoice document
TaxInvoicesGet GET /tax-invoices Get list all tax invocie documents.
TaxInvoicesIdAttachmentPost POST /tax-invoices/{id}/attachment Add Attachment to tax Invoices document.
TaxInvoicesIdDelete DELETE /tax-invoices/{id} Get tax invoices document.
TaxInvoicesIdGet GET /tax-invoices/{id} Get tax invoices document.
TaxInvoicesIdPaymentPost POST /tax-invoices/{id}/payment Change paid status of tax-invoice document.
TaxInvoicesIdStatusKeyStatusIdPost POST /tax-invoices/{id}/status-key/{statusId} Change status of tax invoices document.
TaxInvoicesInlinePost POST /tax-invoices/inline Create tax invocie document with discount and tax inline.
TaxInvoicesPost POST /tax-invoices Create tax invocie document.
TaxInvoicesSharedocumentPost POST /tax-invoices/sharedocument Share link tax invoice document.

TaxInvoicesEmailDocumentPost

SendEmailResponse TaxInvoicesEmailDocumentPost (string authorization, SendEmailCoppies sendEmailCoppies)

Send Email tax invoice document

ส่งเอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน ผ่านทางอีเมล ตามเลขที่เอกสารที่ต้องการ

Example

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

namespace Example
{
    public class TaxInvoicesEmailDocumentPostExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var sendEmailCoppies = new SendEmailCoppies(); // SendEmailCoppies | 

            try
            {
                // Send Email tax invoice document
                SendEmailResponse result = apiInstance.TaxInvoicesEmailDocumentPost(authorization, sendEmailCoppies);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesEmailDocumentPost: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string [default to "Bearer accessToken"]
sendEmailCoppies SendEmailCoppies

Return type

SendEmailResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesGet

InlineDocumentResponse TaxInvoicesGet (int currentPage, int pageSize, string authorization, string sortBy = null, string filter = null)

Get list all tax invocie documents.

เรียกดูข้อมูลเอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน ทั้งหมดในระบบ

Example

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

namespace Example
{
    public class TaxInvoicesGetExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var currentPage = 56;  // int | Query current page document tax invoices. <br>Example Pattern: <ex>/tax-invoices?currentPage=1 </ex><ex>/tax-invoices?currentPage=1&pageSize=20</ex>
            var pageSize = 56;  // int | Query document tax invoices list amount per page. <br>Example Pattern: <ex> /tax-invoices?pageSize=20 </ex>
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var sortBy = sortBy_example;  // string |  (optional) 
            var filter = filter_example;  // string |  (optional) 

            try
            {
                // Get list all tax invocie documents.
                InlineDocumentResponse result = apiInstance.TaxInvoicesGet(currentPage, pageSize, authorization, sortBy, filter);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesGet: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
currentPage int Query current page document tax invoices. <br>Example Pattern: <ex>/tax-invoices?currentPage=1 </ex><ex>/tax-invoices?currentPage=1&pageSize=20</ex>
pageSize int Query document tax invoices list amount per page. <br>Example Pattern: <ex> /tax-invoices?pageSize=20 </ex>
authorization string [default to "Bearer accessToken"]
sortBy string [optional]
filter string [optional]

Return type

InlineDocumentResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesIdAttachmentPost

AttachmentResponse TaxInvoicesIdAttachmentPost (string authorization, string id, System.IO.Stream file = null)

Add Attachment to tax Invoices document.

แนบไฟล์ รูปภาพ หรือ เอกสารที่เกี่ยวข้อง ในเอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน ตามเลขที่เอกสารที่ต้องการ

Example

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

namespace Example
{
    public class TaxInvoicesIdAttachmentPostExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var id = id_example;  // string | documentId หรือ recordId ของเอกสารที่ต้องการแนบ
            var file = BINARY_DATA_HERE;  // System.IO.Stream | รูปแบบ file ที่ใช้แนบในเอกสารเป็นแบบ Binary (optional) 

            try
            {
                // Add Attachment to tax Invoices document.
                AttachmentResponse result = apiInstance.TaxInvoicesIdAttachmentPost(authorization, id, file);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesIdAttachmentPost: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string [default to "Bearer accessToken"]
id string documentId หรือ recordId ของเอกสารที่ต้องการแนบ
file System.IO.Stream รูปแบบ file ที่ใช้แนบในเอกสารเป็นแบบ Binary [optional]

Return type

AttachmentResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: multipart/form-data
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesIdDelete

DeleteResponse TaxInvoicesIdDelete (string authorization, string id)

Get tax invoices document.

ลบ เอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน ตามเลขที่เอกสารที่ต้องการ
** การลบเอกสาร เอกสารต้องอยู่ในสถานะรอดำเนินการ

Example

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

namespace Example
{
    public class TaxInvoicesIdDeleteExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var id = id_example;  // string | ID เอกสารใช้ recordId

            try
            {
                // Get tax invoices document.
                DeleteResponse result = apiInstance.TaxInvoicesIdDelete(authorization, id);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesIdDelete: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string [default to "Bearer accessToken"]
id string ID เอกสารใช้ recordId

Return type

DeleteResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesIdGet

SimpleDocumentResponse TaxInvoicesIdGet (string authorization, string id)

Get tax invoices document.

เรียกดูข้อมูลเอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน ตามเลขที่เอกสารที่ต้องการ

Example

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

namespace Example
{
    public class TaxInvoicesIdGetExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string | ID เอกสารใช้ recordId (default to "Bearer accessToken")
            var id = id_example;  // string | ID เอกสารใช้ recordId

            try
            {
                // Get tax invoices document.
                SimpleDocumentResponse result = apiInstance.TaxInvoicesIdGet(authorization, id);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesIdGet: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string ID เอกสารใช้ recordId [default to "Bearer accessToken"]
id string ID เอกสารใช้ recordId

Return type

SimpleDocumentResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesIdPaymentPost

InlineDocumentResponse TaxInvoicesIdPaymentPost (string authorization, string id, PaymentDocument paymentDocument)

Change paid status of tax-invoice document.

เก็บเงิน เอกสารพร้อมเปลี่ยนสถานะเอกสาร เฉพาะเอกสารใบกำกับภาษี/ใบเสร็จรับเงิน (Tax Invoice/Reciept)

Example

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

namespace Example
{
    public class TaxInvoicesIdPaymentPostExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var id = id_example;  // string | ID เอกสารใช้ recordId หรือ documentId
            var paymentDocument = new PaymentDocument(); // PaymentDocument | 

            try
            {
                // Change paid status of tax-invoice document.
                InlineDocumentResponse result = apiInstance.TaxInvoicesIdPaymentPost(authorization, id, paymentDocument);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesIdPaymentPost: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string [default to "Bearer accessToken"]
id string ID เอกสารใช้ recordId หรือ documentId
paymentDocument PaymentDocument

Return type

InlineDocumentResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesIdStatusKeyStatusIdPost

InlineDocumentResponse TaxInvoicesIdStatusKeyStatusIdPost (string authorization, string id, string statusId)

Change status of tax invoices document.

เปลี่ยนสถานะของเอกสารเอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน สร้างเอกสารใหม่ครั้งแรกจะได้รับสถานะ รอดำเนินการ (awaiting)

Example

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

namespace Example
{
    public class TaxInvoicesIdStatusKeyStatusIdPostExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var id = id_example;  // string | ID เอกสารใช้ recordId
            var statusId = statusId_example;  // string | เปลี่ยนสถานะเอกสารได้ 3 สถานะ <br> awaiting = รอดำเนินการ <br> invoicedelivered = รอเก็บเงิน <br> void = ยกเลิก

            try
            {
                // Change status of tax invoices document.
                InlineDocumentResponse result = apiInstance.TaxInvoicesIdStatusKeyStatusIdPost(authorization, id, statusId);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesIdStatusKeyStatusIdPost: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string [default to "Bearer accessToken"]
id string ID เอกสารใช้ recordId
statusId string เปลี่ยนสถานะเอกสารได้ 3 สถานะ <br> awaiting = รอดำเนินการ <br> invoicedelivered = รอเก็บเงิน <br> void = ยกเลิก

Return type

InlineDocumentResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesInlinePost

InlineDocumentResponse TaxInvoicesInlinePost (string authorization, InlineDocument inlineDocument)

Create tax invocie document with discount and tax inline.

สร้างเอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน แบบส่วนลด หรือ ภาษี แยกตามรายการสินค้า เมื่อสร้างสำเร็จสถานะเอกสารจะอยู่ในสถานะ รอดำเนินการ (awaiting)

ข้อมูลการออกเอกสารใบกำกับภาษี : https://flowaccount.com/blog/ใบกำกับภาษี

Example

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

namespace Example
{
    public class TaxInvoicesInlinePostExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var inlineDocument = new InlineDocument(); // InlineDocument | 

            try
            {
                // Create tax invocie document with discount and tax inline.
                InlineDocumentResponse result = apiInstance.TaxInvoicesInlinePost(authorization, inlineDocument);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesInlinePost: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string [default to "Bearer accessToken"]
inlineDocument InlineDocument

Return type

InlineDocumentResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesPost

SimpleDocumentResponse TaxInvoicesPost (string authorization, SimpleDocument simpleDocument)

Create tax invocie document.

สร้างเอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน เมื่อสร้างสำเร็จสถานะเอกสารจะอยู่ในสถานะ รอดำเนินการ (awaiting)

ข้อมูลการออกเอกสารใบกำกับภาษี : https://flowaccount.com/blog/ใบกำกับภาษี

Example

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

namespace Example
{
    public class TaxInvoicesPostExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var simpleDocument = new SimpleDocument(); // SimpleDocument | 

            try
            {
                // Create tax invocie document.
                SimpleDocumentResponse result = apiInstance.TaxInvoicesPost(authorization, simpleDocument);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesPost: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string [default to "Bearer accessToken"]
simpleDocument SimpleDocument

Return type

SimpleDocumentResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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

TaxInvoicesSharedocumentPost

ShareDocumentResponse TaxInvoicesSharedocumentPost (string authorization, ShareDocument shareDocument)

Share link tax invoice document.

แชร์ลิงค์ เอกสารใบกำกับภาษี หรือ ใบกำกับภาษี/ใบเสร็จรับเงิน ที่ต้องการ จะได้รับลิงค์สำหรับแชร์และเรียกดูเอกสาร

Example

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

namespace Example
{
    public class TaxInvoicesSharedocumentPostExample
    {
        public static void Main()
        {
            Configuration.Default.BasePath = "https://openapi.flowaccount.com/v1";
            var apiInstance = new TaxInvoiceApi(Configuration.Default);
            var authorization = authorization_example;  // string |  (default to "Bearer accessToken")
            var shareDocument = new ShareDocument(); // ShareDocument | 

            try
            {
                // Share link tax invoice document.
                ShareDocumentResponse result = apiInstance.TaxInvoicesSharedocumentPost(authorization, shareDocument);
                Debug.WriteLine(result);
            }
            catch (ApiException e)
            {
                Debug.Print("Exception when calling TaxInvoiceApi.TaxInvoicesSharedocumentPost: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
authorization string [default to "Bearer accessToken"]
shareDocument ShareDocument

Return type

ShareDocumentResponse

Authorization

No authorization required

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 200 response -
401 401 response -
500 500 response -

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