All URIs are relative to https://api-v2.fattureincloud.it
Method | HTTP request | Description |
---|---|---|
createIssuedDocument | POST /c/{company_id}/issued_documents | Create Issued Document |
deleteIssuedDocument | DELETE /c/{company_id}/issued_documents/{document_id} | Delete Issued Document |
deleteIssuedDocumentAttachment | DELETE /c/{company_id}/issued_documents/{document_id}/attachment | Delete Issued Document Attachment |
getEmailData | GET /c/{company_id}/issued_documents/{document_id}/email | Get Email Data |
getExistingIssuedDocumentTotals | POST /c/{company_id}/issued_documents/{document_id}/totals | Get Existing Issued Document Totals |
getIssuedDocument | GET /c/{company_id}/issued_documents/{document_id} | Get Issued Document |
getIssuedDocumentPreCreateInfo | GET /c/{company_id}/issued_documents/info | Get Issued Document Pre-Create Info |
getNewIssuedDocumentTotals | POST /c/{company_id}/issued_documents/totals | Get New Issued Document Totals |
joinIssuedDocuments | GET /c/{company_id}/issued_documents/join | Join Issued Documents |
listIssuedDocuments | GET /c/{company_id}/issued_documents | List Issued Documents |
modifyIssuedDocument | PUT /c/{company_id}/issued_documents/{document_id} | Modify Issued Document |
scheduleEmail | POST /c/{company_id}/issued_documents/{document_id}/email | Schedule Email |
transformIssuedDocument | GET /c/{company_id}/issued_documents/transform | Transform Issued Document |
uploadIssuedDocumentAttachment | POST /c/{company_id}/issued_documents/attachment | Upload Issued Document Attachment |
CreateIssuedDocumentResponse createIssuedDocument(companyId, opts)
Create Issued Document
Creates a new document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let opts = {
'createIssuedDocumentRequest': {"data":{"type":"receipt","numeration":"rec123","subject":"","visible_subject":"","amount_net":68.18,"amount_vat":6.82,"amount_due_discount":0,"entity":{"id":54321,"name":"Mary Red S.r.L.","vat_number":"IT05432181211","tax_code":"IT05432181211","address_street":"Via Italia, 66","address_postal_code":"20900","address_city":"Milano","address_province":"MI","address_extra":"","country":"Italia","certified_email":"[email protected]","ei_code":"ABCXCR1"},"date":"2021-08-20","number":1,"next_due_date":"2021-12-31","attachment_token":"ypbqqe4u8w8bdabcd5fd5b1a","items_list":[{"product_id":333,"code":"SG3","name":"Soggiorno","measure":"","net_price":68.18182,"category":"","id":277875565,"gross_price":75,"apply_withholding_taxes":true,"discount":0,"discount_highlight":false,"in_dn":false,"qty":1,"vat":{"id":3,"value":10,"description":""},"stock":true,"description":"","not_taxable":false}],"payments_list":[{"amount":75,"due_date":"2020-08-23","id":444,"payment_terms":{"days":0,"type":"standard"},"status":"not_paid"}],"payment_method":{"id":4}}} // CreateIssuedDocumentRequest | The Issued Document
};
apiInstance.createIssuedDocument(companyId, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
createIssuedDocumentRequest | CreateIssuedDocumentRequest | The Issued Document | [optional] |
- Content-Type: application/json
- Accept: application/json
deleteIssuedDocument(companyId, documentId)
Delete Issued Document
Deletes the specified document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let documentId = 56; // Number | The ID of the document.
apiInstance.deleteIssuedDocument(companyId, documentId).then(() => {
console.log('API called successfully.');
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
documentId | Number | The ID of the document. |
null (empty response body)
- Content-Type: Not defined
- Accept: Not defined
deleteIssuedDocumentAttachment(companyId, documentId)
Delete Issued Document Attachment
Removes the attachment of the specified document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let documentId = 56; // Number | The ID of the document.
apiInstance.deleteIssuedDocumentAttachment(companyId, documentId).then(() => {
console.log('API called successfully.');
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
documentId | Number | The ID of the document. |
null (empty response body)
- Content-Type: Not defined
- Accept: Not defined
GetEmailDataResponse getEmailData(companyId, documentId)
Get Email Data
Gets the pre-compiled email details.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let documentId = 56; // Number | The ID of the document.
apiInstance.getEmailData(companyId, documentId).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
documentId | Number | The ID of the document. |
- Content-Type: Not defined
- Accept: application/json
GetExistingIssuedDocumentTotalsResponse getExistingIssuedDocumentTotals(companyId, documentId, opts)
Get Existing Issued Document Totals
Returns the totals for a specified document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let documentId = 56; // Number | The ID of the document.
let opts = {
'getExistingIssuedDocumentTotalsRequest': {"data":{"rivalsa":20}} // GetExistingIssuedDocumentTotalsRequest |
};
apiInstance.getExistingIssuedDocumentTotals(companyId, documentId, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
documentId | Number | The ID of the document. | |
getExistingIssuedDocumentTotalsRequest | GetExistingIssuedDocumentTotalsRequest | [optional] |
GetExistingIssuedDocumentTotalsResponse
- Content-Type: application/json
- Accept: application/json
GetIssuedDocumentResponse getIssuedDocument(companyId, documentId, opts)
Get Issued Document
Gets the specified document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let documentId = 56; // Number | The ID of the document.
let opts = {
'fields': "fields_example", // String | List of comma-separated fields.
'fieldset': "fieldset_example" // String | Name of the fieldset.
};
apiInstance.getIssuedDocument(companyId, documentId, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
documentId | Number | The ID of the document. | |
fields | String | List of comma-separated fields. | [optional] |
fieldset | String | Name of the fieldset. | [optional] |
- Content-Type: Not defined
- Accept: application/json
GetIssuedDocumentPreCreateInfoResponse getIssuedDocumentPreCreateInfo(companyId, type)
Get Issued Document Pre-Create Info
Retrieves the information useful while creating a new document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let type = "type_example"; // String | The type of the issued document.
apiInstance.getIssuedDocumentPreCreateInfo(companyId, type).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
type | String | The type of the issued document. |
GetIssuedDocumentPreCreateInfoResponse
- Content-Type: Not defined
- Accept: application/json
GetNewIssuedDocumentTotalsResponse getNewIssuedDocumentTotals(companyId, opts)
Get New Issued Document Totals
Returns the totals for a new document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let opts = {
'getNewIssuedDocumentTotalsRequest': {"data":{"id":12345,"type":"receipt","year":2021,"numeration":"rec123","subject":"","visible_subject":"","rc_center":"","stamp_duty":0,"use_gross_prices":false,"delivery_note":false,"accompanying_invoice":false,"amount_net":68.18,"amount_vat":6.82,"amount_due_discount":0,"amount_rivalsa":0,"amount_cassa":0,"amount_withholding_tax":0,"amount_other_withholding_tax":0,"h_margins":15,"v_margins":16,"show_payment_method":false,"show_payments":true,"show_totals":"all","show_notification_button":false,"is_marked":false,"created_at":"2021-08-13 09:30:20","updated_at":"2021-08-23 05:34:20","entity":{"id":54321,"name":"Mary Red S.r.L.","vat_number":"IT05432181211","tax_code":"IT05432181211","address_street":"Via Italia, 66","address_postal_code":"20900","address_city":"Milano","address_province":"MI","address_extra":"","country":"Italia","certified_email":"[email protected]","ei_code":"ABCXCR1"},"date":"2021-08-20","number":1,"currency":{"id":"EUR","exchange_rate":"1.00000","symbol":"€"},"language":{"code":"it","name":"Italiano"},"notes":"","rivalsa":0,"cassa":0,"withholding_tax":0,"withholding_tax_taxable":100,"other_withholding_tax":0,"payment_method":{"id":4,"name":"Credit card"},"use_split_payment":false,"items_list":[{"product_id":5432,"code":"SG3","name":"Soggiorno","measure":"","net_price":68.18182,"category":"","id":277876033,"apply_withholding_taxes":true,"discount":0,"discount_highlight":false,"in_dn":false,"qty":1,"vat":{"id":3,"value":10,"description":""},"stock":false,"description":"","not_taxable":false}],"payments_list":[{"amount":75,"due_date":"2020-08-23","id":69078013,"payment_terms":{"days":0,"type":"standard"},"status":"not_paid"}],"attachment_url":"kdijrnf893hnwkfk45f50f.pdf","next_due_date":"2020-08-23","template":{"id":2821,"name":"Light Smoke"},"url":"y12h45rn9yf2mse0p43t7ec90vr.pdf"}} // GetNewIssuedDocumentTotalsRequest |
};
apiInstance.getNewIssuedDocumentTotals(companyId, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
getNewIssuedDocumentTotalsRequest | GetNewIssuedDocumentTotalsRequest | [optional] |
GetNewIssuedDocumentTotalsResponse
- Content-Type: application/json
- Accept: application/json
JoinIssuedDocumentsResponse joinIssuedDocuments(companyId, ids, opts)
Join Issued Documents
Joins issued documents.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let ids = "1,2,3,4"; // String | Ids of the documents.
let opts = {
'group': 56, // Number | Group items.
'type': "delivery_notes, orders, quotes, work_reports" // String | Type of the documents to be joined
};
apiInstance.joinIssuedDocuments(companyId, ids, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
ids | String | Ids of the documents. | |
group | Number | Group items. | [optional] |
type | String | Type of the documents to be joined | [optional] |
- Content-Type: Not defined
- Accept: application/json
ListIssuedDocumentsResponse listIssuedDocuments(companyId, type, opts)
List Issued Documents
Lists the issued documents.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let type = "type_example"; // String | The type of the issued document.
let opts = {
'fields': "fields_example", // String | List of comma-separated fields.
'fieldset': "fieldset_example", // String | Name of the fieldset.
'sort': "sort_example", // String | List of comma-separated fields for result sorting (minus for desc sorting).
'page': 1, // Number | The page to retrieve.
'perPage': 5, // Number | The size of the page.
'q': "q_example", // String | Query for filtering the results.
'inclusive': 56 // Number | (Only for type = delivery_notes) Include invoices delivery notes.
};
apiInstance.listIssuedDocuments(companyId, type, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
type | String | The type of the issued document. | |
fields | String | List of comma-separated fields. | [optional] |
fieldset | String | Name of the fieldset. | [optional] |
sort | String | List of comma-separated fields for result sorting (minus for desc sorting). | [optional] |
page | Number | The page to retrieve. | [optional] [default to 1] |
perPage | Number | The size of the page. | [optional] [default to 5] |
q | String | Query for filtering the results. | [optional] |
inclusive | Number | (Only for type = delivery_notes) Include invoices delivery notes. | [optional] |
- Content-Type: Not defined
- Accept: application/json
ModifyIssuedDocumentResponse modifyIssuedDocument(companyId, documentId, opts)
Modify Issued Document
Modifies the specified document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let documentId = 56; // Number | The ID of the document.
let opts = {
'modifyIssuedDocumentRequest': {"data":{"type":"receipt","numeration":"rec123","subject":"","visible_subject":"","amount_net":68.18,"amount_vat":6.82,"amount_due_discount":0,"entity":{"id":54321,"name":"Mary Red S.r.L.","vat_number":"IT05432181211","tax_code":"IT05432181211","address_street":"Via Italia, 66","address_postal_code":"20900","address_city":"Milano","address_province":"MI","address_extra":"","country":"Italia","certified_email":"[email protected]","ei_code":"ABCXCR1"},"date":"2021-08-20","number":1,"next_due_date":"2021-12-31","attachment_token":"ypbqqe4u8w8bdabcd5fd5b1a","items_list":[{"product_id":333,"code":"SG3","name":"Soggiorno","measure":"","net_price":68.18182,"category":"","id":277875565,"gross_price":75,"apply_withholding_taxes":true,"discount":0,"discount_highlight":false,"in_dn":false,"qty":1,"vat":{"id":3,"value":10,"description":""},"stock":true,"description":"","not_taxable":false}],"payments_list":[{"amount":75,"due_date":"2020-08-23","id":444,"payment_terms":{"days":0,"type":"standard"},"status":"not_paid"}]}} // ModifyIssuedDocumentRequest | The modified document
};
apiInstance.modifyIssuedDocument(companyId, documentId, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
documentId | Number | The ID of the document. | |
modifyIssuedDocumentRequest | ModifyIssuedDocumentRequest | The modified document | [optional] |
- Content-Type: application/json
- Accept: application/json
scheduleEmail(companyId, documentId, opts)
Schedule Email
Schedules the sending of a document by email.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let documentId = 56; // Number | The ID of the document.
let opts = {
'scheduleEmailRequest': {"data":{"sender_email":"[email protected]","recipient_email":"[email protected]","subject":"Nostra pro forma nr. 1","body":"Gentile Mario Rossi,<br>per vedere la nostra pro forma di o per scaricarne una copia in versione PDF prema sul bottone sottostante.<br><br>{{allegati}}<br><br>Cordiali saluti,<br><b>Mario Rossi</b>","include":{"document":false,"delivery_note":false,"attachment":false,"accompanying_invoice":false},"attach_pdf":true,"send_copy":false}} // ScheduleEmailRequest | Email Schedule
};
apiInstance.scheduleEmail(companyId, documentId, opts).then(() => {
console.log('API called successfully.');
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
documentId | Number | The ID of the document. | |
scheduleEmailRequest | ScheduleEmailRequest | Email Schedule | [optional] |
null (empty response body)
- Content-Type: application/json
- Accept: Not defined
TransformIssuedDocumentResponse transformIssuedDocument(companyId, originalDocumentId, newType, opts)
Transform Issued Document
Transforms the document.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let originalDocumentId = 56; // Number | Original document id.
let newType = "newType_example"; // String | New document type.
let opts = {
'type': "type_example", // String | Current document type.
'eInvoice': 56, // Number | New document e_invoice.
'transformKeepCopy': 56 // Number | Keep the old document.
};
apiInstance.transformIssuedDocument(companyId, originalDocumentId, newType, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
originalDocumentId | Number | Original document id. | |
newType | String | New document type. | |
type | String | Current document type. | [optional] |
eInvoice | Number | New document e_invoice. | [optional] |
transformKeepCopy | Number | Keep the old document. | [optional] |
TransformIssuedDocumentResponse
- Content-Type: Not defined
- Accept: application/json
UploadIssuedDocumentAttachmentResponse uploadIssuedDocumentAttachment(companyId, opts)
Upload Issued Document Attachment
Uploads an attachment destined to an issued document. The actual association between the document and the attachment must be implemented separately, using the returned token.
import fattureInCloudSdk from '@fattureincloud/fattureincloud-js-sdk';
let defaultClient = fattureInCloudSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
let OAuth2AuthenticationCodeFlow = defaultClient.authentications['OAuth2AuthenticationCodeFlow'];
OAuth2AuthenticationCodeFlow.accessToken = 'YOUR ACCESS TOKEN';
let apiInstance = new fattureInCloudSdk.IssuedDocumentsApi();
let companyId = 12345; // Number | The ID of the company.
let opts = {
'filename': "filename_example", // String | Attachment file name
'attachment': "/path/to/file" // File | Attachment file [.png, .jpg, .gif, .pdf, .zip, .xls, .xlsx, .doc, .docx]
};
apiInstance.uploadIssuedDocumentAttachment(companyId, opts).then((result) => {
console.log('API called successfully. Returned result: ' + JSON.stringify(result));
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
companyId | Number | The ID of the company. | |
filename | String | Attachment file name | [optional] |
attachment | File | Attachment file [.png, .jpg, .gif, .pdf, .zip, .xls, .xlsx, .doc, .docx] | [optional] |
UploadIssuedDocumentAttachmentResponse
- Content-Type: multipart/form-data
- Accept: application/json