All URIs are relative to https://api-v2.fattureincloud.it
Method | HTTP request | Description |
---|---|---|
GetEInvoiceRejectionReason | Get /c/{company_id}/issued_documents/{document_id}/e_invoice/error_reason | Get E-Invoice Rejection Reason |
GetEInvoiceXml | Get /c/{company_id}/issued_documents/{document_id}/e_invoice/xml | Get E-Invoice XML |
SendEInvoice | Post /c/{company_id}/issued_documents/{document_id}/e_invoice/send | Send E-Invoice |
VerifyEInvoiceXml | Get /c/{company_id}/issued_documents/{document_id}/e_invoice/xml_verify | Verify E-Invoice XML |
GetEInvoiceRejectionReasonResponse GetEInvoiceRejectionReason(ctx, companyId, documentId).Execute()
Get E-Invoice Rejection Reason
package main
import (
"context"
"encoding/json"
"fmt"
"os"
fattureincloudapi "github.com/fattureincloud/fattureincloud-go-sdk/v2/api"
fattureincloud "github.com/fattureincloud/fattureincloud-go-sdk/v2/model"
)
func main() {
companyId := int32(12345) // int32 | The ID of the company.
documentId := int32(56) // int32 | The ID of the document.
auth := context.WithValue(context.Background(), fattureincloudapi.ContextAccessToken, "ACCESS_TOKEN")
configuration := fattureincloudapi.NewConfiguration()
apiClient := fattureincloudapi.NewAPIClient(configuration)
resp, r, err := apiClient.IssuedEInvoicesAPI.GetEInvoiceRejectionReason(auth, companyId, documentId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `IssuedEInvoicesAPI.GetEInvoiceRejectionReason``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetEInvoiceRejectionReason`: GetEInvoiceRejectionReasonResponse
json.NewEncoder(os.Stdout).Encode(resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
companyId | int32 | The ID of the company. | |
documentId | int32 | The ID of the document. |
Other parameters are passed through a pointer to a apiGetEInvoiceRejectionReasonRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
GetEInvoiceRejectionReasonResponse
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
string GetEInvoiceXml(ctx, companyId, documentId).IncludeAttachment(includeAttachment).Execute()
Get E-Invoice XML
package main
import (
"context"
"encoding/json"
"fmt"
"os"
fattureincloudapi "github.com/fattureincloud/fattureincloud-go-sdk/v2/api"
fattureincloud "github.com/fattureincloud/fattureincloud-go-sdk/v2/model"
)
func main() {
companyId := int32(12345) // int32 | The ID of the company.
documentId := int32(56) // int32 | The ID of the document.
includeAttachment := true // bool | Include the attachment to the XML e-invoice. (optional)
auth := context.WithValue(context.Background(), fattureincloudapi.ContextAccessToken, "ACCESS_TOKEN")
configuration := fattureincloudapi.NewConfiguration()
apiClient := fattureincloudapi.NewAPIClient(configuration)
resp, r, err := apiClient.IssuedEInvoicesAPI.GetEInvoiceXml(auth, companyId, documentId).IncludeAttachment(includeAttachment).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `IssuedEInvoicesAPI.GetEInvoiceXml``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetEInvoiceXml`: string
json.NewEncoder(os.Stdout).Encode(resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
companyId | int32 | The ID of the company. | |
documentId | int32 | The ID of the document. |
Other parameters are passed through a pointer to a apiGetEInvoiceXmlRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
includeAttachment | bool | Include the attachment to the XML e-invoice. |
string
- Content-Type: Not defined
- Accept: text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SendEInvoiceResponse SendEInvoice(ctx, companyId, documentId).SendEInvoiceRequest(sendEInvoiceRequest).Execute()
Send E-Invoice
package main
import (
"context"
"encoding/json"
"fmt"
"os"
fattureincloudapi "github.com/fattureincloud/fattureincloud-go-sdk/v2/api"
fattureincloud "github.com/fattureincloud/fattureincloud-go-sdk/v2/model"
)
func main() {
companyId := int32(12345) // int32 | The ID of the company.
documentId := int32(56) // int32 | The ID of the document.
sendEInvoiceRequest := *fattureincloud.NewSendEInvoiceRequest() // SendEInvoiceRequest | (optional)
auth := context.WithValue(context.Background(), fattureincloudapi.ContextAccessToken, "ACCESS_TOKEN")
configuration := fattureincloudapi.NewConfiguration()
apiClient := fattureincloudapi.NewAPIClient(configuration)
resp, r, err := apiClient.IssuedEInvoicesAPI.SendEInvoice(auth, companyId, documentId).SendEInvoiceRequest(sendEInvoiceRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `IssuedEInvoicesAPI.SendEInvoice``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `SendEInvoice`: SendEInvoiceResponse
json.NewEncoder(os.Stdout).Encode(resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
companyId | int32 | The ID of the company. | |
documentId | int32 | The ID of the document. |
Other parameters are passed through a pointer to a apiSendEInvoiceRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
sendEInvoiceRequest | SendEInvoiceRequest | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
VerifyEInvoiceXmlResponse VerifyEInvoiceXml(ctx, companyId, documentId).Execute()
Verify E-Invoice XML
package main
import (
"context"
"encoding/json"
"fmt"
"os"
fattureincloudapi "github.com/fattureincloud/fattureincloud-go-sdk/v2/api"
fattureincloud "github.com/fattureincloud/fattureincloud-go-sdk/v2/model"
)
func main() {
companyId := int32(12345) // int32 | The ID of the company.
documentId := int32(56) // int32 | The ID of the document.
auth := context.WithValue(context.Background(), fattureincloudapi.ContextAccessToken, "ACCESS_TOKEN")
configuration := fattureincloudapi.NewConfiguration()
apiClient := fattureincloudapi.NewAPIClient(configuration)
resp, r, err := apiClient.IssuedEInvoicesAPI.VerifyEInvoiceXml(auth, companyId, documentId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `IssuedEInvoicesAPI.VerifyEInvoiceXml``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `VerifyEInvoiceXml`: VerifyEInvoiceXmlResponse
json.NewEncoder(os.Stdout).Encode(resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
companyId | int32 | The ID of the company. | |
documentId | int32 | The ID of the document. |
Other parameters are passed through a pointer to a apiVerifyEInvoiceXmlRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]