UNPKG

green-invoice-graphql

Version:
1,582 lines 41.2 kB
module.exports = { "$ref": "#/definitions/_schema", "definitions": { "updateExpenseRequest_paymentType_oneOf_0": { "type": "boolean", "title": "updateExpenseRequest_paymentType_oneOf_0" }, "updateExpenseRequest_paymentType_oneOf_1": { "type": [ "string", "number" ], "enum": [ "1", "2", "3", "4", "5", "10", "11", 1, 2, 3, 4, 5, 10, 11 ], "title": "updateExpenseRequest_paymentType_oneOf_1" }, "updateExpenseRequest_paymentType": { "description": "Payment method", "oneOf": [ { "$ref": "#/definitions/updateExpenseRequest_paymentType_oneOf_0" }, { "$ref": "#/definitions/updateExpenseRequest_paymentType_oneOf_1" } ], "title": "updateExpenseRequest_paymentType" }, "Currency": { "type": "string", "description": "3-letter ISO item currency code", "enum": [ "ILS", "USD", "EUR", "GBP", "JPY", "CHF", "CNY", "AUD", "CAD", "RUB", "BRL", "HKD", "SGD", "THB", "MXN", "TRY", "NZD", "SEK", "NOK", "DKK", "KRW", "INR", "IDR", "PLN", "RON", "ZAR", "HRK" ], "title": "Currency" }, "updateExpenseRequest_currencyRate": { "type": "number", "description": "Currency rate relative to ILS", "title": "updateExpenseRequest_currencyRate" }, "updateExpenseRequest_vat": { "type": "number", "description": "The amount of the vat", "title": "updateExpenseRequest_vat" }, "updateExpenseRequest_amount": { "type": "number", "description": "The total amount of the expense", "title": "updateExpenseRequest_amount" }, "updateExpenseRequest_date": { "type": "string", "description": "Date of the expense", "title": "updateExpenseRequest_date" }, "updateExpenseRequest_dueDate": { "type": "string", "description": "Due date of the expense", "title": "updateExpenseRequest_dueDate" }, "updateExpenseRequest_reportingDate": { "type": "string", "description": "Reporting date of the expense", "title": "updateExpenseRequest_reportingDate" }, "updateExpenseRequest_documentType": { "type": "number", "description": "Document type", "enum": [ 20, 305, 320, 330, 400, 405 ], "title": "updateExpenseRequest_documentType" }, "updateExpenseRequest_number": { "type": "string", "description": "Number of the expense", "title": "updateExpenseRequest_number" }, "updateExpenseRequest_description": { "type": "string", "description": "Description for the expense", "title": "updateExpenseRequest_description" }, "updateExpenseRequest_remarks": { "type": "string", "string": "Remarks for the expense", "title": "updateExpenseRequest_remarks" }, "Supplier_id": { "type": "string", "description": "The supplier ID", "title": "Supplier_id" }, "Supplier_name": { "type": "string", "description": "The supplier name", "title": "Supplier_name" }, "Supplier_active": { "type": "boolean", "description": "Is the supplier active or not", "title": "Supplier_active" }, "Supplier_taxId": { "type": "string", "description": "The supplier tax ID", "title": "Supplier_taxId" }, "Supplier_paymentTerms": { "type": "number", "description": "The supplier payment term, default is 0", "enum": [ -1, 0, 10, 15, 30, 45, 60, 75, 90, 120 ], "title": "Supplier_paymentTerms" }, "Supplier_bankName": { "type": "string", "description": "The supplier bank name", "title": "Supplier_bankName" }, "Supplier_bankBranch": { "type": "string", "description": "The supplier bank branch number", "title": "Supplier_bankBranch" }, "Supplier_bankAccount": { "type": "string", "description": "The supplier bank account number", "title": "Supplier_bankAccount" }, "Country": { "type": "string", "description": "2-letter ISO supplier country code, default is IL", "enum": [ "UG", "UZ", "AT", "AU", "UA", "UY", "AZ", "CX", "AE", "IT", "BS", "GS", "UM", "VI", "VG", "HM", "TC", "MP", "MH", "SB", "FO", "FK", "FJ", "KM", "CK", "CC", "KY", "ID", "IS", "IE", "IR", "SV", "AL", "DZ", "AX", "AO", "AI", "AD", "AQ", "AG", "EE", "AF", "EC", "AR", "US", "AW", "ER", "AM", "ET", "BT", "BV", "BW", "BG", "BO", "BA", "BI", "BF", "BH", "BY", "BE", "BZ", "BD", "BJ", "BB", "BN", "BR", "GB", "BM", "DJ", "JM", "JE", "GA", "GE", "GH", "GT", "GU", "GP", "GY", "GI", "GN", "GW", "GQ", "GF", "GM", "GL", "DE", "GD", "GG", "DM", "DK", "ZA", "SS", "KR", "IM", "NF", "HT", "MV", "BQ", "IN", "NL", "HK", "HU", "HN", "IO", "TF", "PH", "DO", "CD", "CF", "PS", "WF", "VN", "VU", "VE", "VA", "ZW", "ZM", "CI", "TJ", "TV", "TG", "TO", "TN", "TK", "TR", "TM", "TW", "TZ", "TT", "GR", "JP", "JO", "IL", "KW", "CV", "LA", "LB", "LY", "LU", "LV", "LR", "LT", "LI", "LS", "MR", "MU", "ML", "MG", "MZ", "MD", "MN", "ME", "MS", "MC", "TL", "MM", "YT", "FM", "MW", "MY", "MT", "EG", "MO", "MK", "MX", "MA", "MQ", "NR", "NO", "NG", "NZ", "NU", "NE", "NI", "NA", "NP", "ST", "SJ", "EH", "SD", "SZ", "SO", "SY", "SR", "SL", "SC", "CN", "SG", "SI", "SK", "WS", "AS", "BL", "MF", "SM", "PM", "SN", "SH", "VC", "LC", "SX", "KN", "SA", "ES", "RS", "LK", "OM", "IQ", "PW", "PL", "PF", "PR", "PT", "PN", "FI", "PA", "PG", "PK", "PY", "PE", "TD", "CL", "CZ", "KP", "FR", "CU", "CO", "CG", "XK", "CR", "CW", "KZ", "QA", "KG", "KI", "NC", "KH", "CM", "CA", "KE", "CY", "HR", "RE", "RW", "RO", "RU", "SE", "CH", "TH", "YE" ], "title": "Country" }, "Supplier_phone": { "type": "string", "description": "The supplier phone number", "title": "Supplier_phone" }, "Supplier_mobile": { "type": "string", "description": "The supplier mobile number", "title": "Supplier_mobile" }, "Supplier_contactPerson": { "type": "string", "description": "The supplier contact person name", "title": "Supplier_contactPerson" }, "Supplier_emails_items": { "type": "string", "title": "Supplier_emails_items" }, "Supplier_emails": { "type": "array", "additionalItems": false, "items": { "$ref": "#/definitions/Supplier_emails_items" }, "title": "Supplier_emails" }, "Supplier_creationDate": { "type": "integer", "description": "The creation date of the supplier, in UNIX timestamp format", "title": "Supplier_creationDate" }, "Supplier_lastUpdateDate": { "type": "integer", "description": "The last update date of the supplier, in UNIX timestamp format", "title": "Supplier_lastUpdateDate" }, "Supplier_department": { "type": "string", "description": "The supplier department", "title": "Supplier_department" }, "Supplier_accountingKey": { "type": "string", "description": "The supplier accounting key", "title": "Supplier_accountingKey" }, "Supplier_address": { "type": "string", "description": "The supplier address", "title": "Supplier_address" }, "Supplier_city": { "type": "string", "description": "The supplier city", "title": "Supplier_city" }, "Supplier_zip": { "type": "string", "description": "The supplier zip code", "title": "Supplier_zip" }, "Supplier_fax": { "type": "string", "description": "The supplier fax number", "title": "Supplier_fax" }, "Supplier_remarks": { "type": "string", "description": "The Supplier remarks for self use", "title": "Supplier_remarks" }, "Supplier_incomeAmount": { "type": "number", "description": "The amount of incomes from the customer", "title": "Supplier_incomeAmount" }, "Supplier_paymentAmount": { "type": "number", "title": "Supplier_paymentAmount" }, "Supplier_balanceAmount": { "type": "number", "description": "The balance amount of the supplier", "title": "Supplier_balanceAmount" }, "Supplier": { "type": "object", "additionalProperties": false, "description": "Supplier of the expense", "properties": { "id": { "$ref": "#/definitions/Supplier_id" }, "name": { "$ref": "#/definitions/Supplier_name" }, "active": { "$ref": "#/definitions/Supplier_active" }, "taxId": { "$ref": "#/definitions/Supplier_taxId" }, "paymentTerms": { "$ref": "#/definitions/Supplier_paymentTerms" }, "bankName": { "$ref": "#/definitions/Supplier_bankName" }, "bankBranch": { "$ref": "#/definitions/Supplier_bankBranch" }, "bankAccount": { "$ref": "#/definitions/Supplier_bankAccount" }, "country": { "$ref": "#/definitions/Country" }, "phone": { "$ref": "#/definitions/Supplier_phone" }, "mobile": { "$ref": "#/definitions/Supplier_mobile" }, "contactPerson": { "$ref": "#/definitions/Supplier_contactPerson" }, "emails": { "$ref": "#/definitions/Supplier_emails" }, "labels": { "$ref": "#/definitions/Supplier_emails" }, "creationDate": { "$ref": "#/definitions/Supplier_creationDate" }, "lastUpdateDate": { "$ref": "#/definitions/Supplier_lastUpdateDate" }, "department": { "$ref": "#/definitions/Supplier_department" }, "accountingKey": { "$ref": "#/definitions/Supplier_accountingKey" }, "address": { "$ref": "#/definitions/Supplier_address" }, "city": { "$ref": "#/definitions/Supplier_city" }, "zip": { "$ref": "#/definitions/Supplier_zip" }, "fax": { "$ref": "#/definitions/Supplier_fax" }, "remarks": { "$ref": "#/definitions/Supplier_remarks" }, "incomeAmount": { "$ref": "#/definitions/Supplier_incomeAmount" }, "paymentAmount": { "$ref": "#/definitions/Supplier_paymentAmount" }, "balanceAmount": { "$ref": "#/definitions/Supplier_balanceAmount" } }, "title": "Supplier" }, "AccountingClassification_id": { "type": "string", "description": "The classification ID, see 'Get Accounting Classifications' endpoint", "title": "AccountingClassification_id" }, "AccountingClassification_key": { "type": "string", "description": "The classification key", "title": "AccountingClassification_key" }, "AccountingClassification_code": { "type": "string", "description": "The classification code", "title": "AccountingClassification_code" }, "AccountingClassification_title": { "type": "string", "description": "The classification title", "title": "AccountingClassification_title" }, "AccountingClassification_irsCode": { "type": "number", "description": "The classification IRS code", "enum": [ 1306, 1307, 1310, 1320, 1330, 1340, 1390, 3011, 3012, 3015, 3055, 3060, 3066, 3067, 3068, 3070, 3075, 3080, 3085, 3090, 3100, 3120, 3511, 3512, 3515, 3520, 3535, 3540, 3545, 3550, 3555, 3560, 3566, 3567, 3568, 3570, 3575, 3580, 3590, 3595, 3600, 3620, 3625, 3640, 3650, 3660, 3665, 3680, 5010, 5090, 8040, 8050, 8060, 8080, 8090 ], "title": "AccountingClassification_irsCode" }, "AccountingClassification_income": { "type": "number", "description": "The classification income", "title": "AccountingClassification_income" }, "AccountingClassification_type": { "type": "number", "description": "The classification type", "title": "AccountingClassification_type" }, "AccountingClassification_vat": { "type": "number", "description": "The classification VAT", "title": "AccountingClassification_vat" }, "AccountingClassification": { "type": "object", "additionalProperties": false, "description": "Account classification of the expense", "properties": { "id": { "$ref": "#/definitions/AccountingClassification_id" }, "key": { "$ref": "#/definitions/AccountingClassification_key" }, "code": { "$ref": "#/definitions/AccountingClassification_code" }, "title": { "$ref": "#/definitions/AccountingClassification_title" }, "irsCode": { "$ref": "#/definitions/AccountingClassification_irsCode" }, "income": { "$ref": "#/definitions/AccountingClassification_income" }, "type": { "$ref": "#/definitions/AccountingClassification_type" }, "vat": { "$ref": "#/definitions/AccountingClassification_vat" } }, "title": "AccountingClassification" }, "updateExpenseRequest_active": { "type": "boolean", "description": "Is the expense active or not", "title": "updateExpenseRequest_active" }, "Expense_addRecipient": { "type": "boolean", "description": "Should we save the supplier or not (by setting this to true you are required to add a supplier)", "title": "Expense_addRecipient" }, "Expense_addAccountingClassification": { "type": "boolean", "description": "Should we save the accounting classification (by setting this to true you are required to add an accounting classification that contains title & irsCode)", "title": "Expense_addAccountingClassification" }, "Expense": { "type": "object", "additionalProperties": false, "description": "A Single Expense", "properties": { "paymentType": { "$ref": "#/definitions/updateExpenseRequest_paymentType" }, "currency": { "$ref": "#/definitions/Currency" }, "currencyRate": { "$ref": "#/definitions/updateExpenseRequest_currencyRate" }, "vat": { "$ref": "#/definitions/updateExpenseRequest_vat" }, "amount": { "$ref": "#/definitions/updateExpenseRequest_amount" }, "date": { "$ref": "#/definitions/updateExpenseRequest_date" }, "dueDate": { "$ref": "#/definitions/updateExpenseRequest_dueDate" }, "reportingDate": { "$ref": "#/definitions/updateExpenseRequest_reportingDate" }, "documentType": { "$ref": "#/definitions/updateExpenseRequest_documentType" }, "number": { "$ref": "#/definitions/updateExpenseRequest_number" }, "description": { "$ref": "#/definitions/updateExpenseRequest_description" }, "remarks": { "$ref": "#/definitions/updateExpenseRequest_remarks" }, "supplier": { "$ref": "#/definitions/Supplier" }, "accountingClassification": { "$ref": "#/definitions/AccountingClassification" }, "active": { "$ref": "#/definitions/updateExpenseRequest_active" }, "addRecipient": { "$ref": "#/definitions/Expense_addRecipient" }, "addAccountingClassification": { "$ref": "#/definitions/Expense_addAccountingClassification" } }, "required": [ "currency", "vat", "amount", "date", "reportingDate", "documentType", "number", "supplier", "accountingClassification" ], "title": "Expense" }, "ErrorResponse": { "type": "object", "additionalProperties": false, "description": "Error", "properties": { "errorCode": { "$ref": "#/definitions/Supplier_paymentAmount" }, "errorMessage": { "$ref": "#/definitions/Supplier_emails_items" } }, "title": "ErrorResponse" }, "addExpenseResponse": { "oneOf": [ { "$ref": "#/definitions/Expense" }, { "$ref": "#/definitions/ErrorResponse" } ], "title": "addExpenseResponse" }, "GetExpenseDraft_id": { "type": "string", "description": "The expense draft ID", "title": "GetExpenseDraft_id" }, "GetExpenseDraft_status": { "type": "number", "description": "The status of the expense draft", "enum": [ 10, 50 ], "title": "GetExpenseDraft_status" }, "GetExpenseDraft_creationDate": { "type": "integer", "description": "The creation date of the expense draft, in UNIX timestamp format", "title": "GetExpenseDraft_creationDate" }, "GetExpenseDraft_lastUpdateDate": { "type": "integer", "description": "The last update date of the expense draft, in UNIX timestamp format", "title": "GetExpenseDraft_lastUpdateDate" }, "GetExpense_thumbnail": { "type": "string", "description": "URL of expense thumbnail", "title": "GetExpense_thumbnail" }, "GetExpense_url": { "type": "string", "description": "URL to download the expense thumbnail", "title": "GetExpense_url" }, "GetExpenseDraft": { "type": "object", "additionalProperties": false, "required": [ "description", "result" ], "properties": { "id": { "$ref": "#/definitions/GetExpenseDraft_id" }, "status": { "$ref": "#/definitions/GetExpenseDraft_status" }, "creationDate": { "$ref": "#/definitions/GetExpenseDraft_creationDate" }, "lastUpdateDate": { "$ref": "#/definitions/GetExpenseDraft_lastUpdateDate" }, "expense": { "$ref": "#/definitions/Expense" }, "thumbnail": { "$ref": "#/definitions/GetExpense_thumbnail" }, "url": { "$ref": "#/definitions/GetExpense_url" } }, "title": "GetExpenseDraft" }, "Mutation": { "type": "object", "title": "Mutation", "properties": { "addExpense": { "$ref": "#/definitions/addExpenseResponse" }, "addExpenseDraftByFile": { "$ref": "#/definitions/GetExpenseDraft" } } }, "addExpenseDraftByFileRequest_file": { "type": "string", "description": "The file, in Base64, allowed types: GIF, PNG, JPG, SVG, PDF", "title": "addExpenseDraftByFileRequest_file" }, "addExpenseDraftByFileRequest": { "type": "object", "additionalProperties": false, "required": [], "properties": { "file": { "$ref": "#/definitions/addExpenseDraftByFileRequest_file" } }, "title": "addExpenseDraftByFileRequest" }, "MutationInput": { "type": "object", "title": "MutationInput", "properties": { "addExpense": { "$ref": "#/definitions/Expense" }, "addExpenseDraftByFile": { "$ref": "#/definitions/addExpenseDraftByFileRequest" } } }, "getExpenseRequest_id": { "type": "string", "description": "The expense ID", "title": "getExpenseRequest_id" }, "GetExpense_businessType": { "type": "number", "description": "The business type ID", "enum": [ 1, 2, 3, 4, 5, 6 ], "title": "GetExpense_businessType" }, "GetExpense_documentType": { "type": "number", "description": "The type of the expense", "enum": [ 20, 305, 320, 330, 400, 405 ], "title": "GetExpense_documentType" }, "GetExpense_status": { "type": "number", "description": "The status of the expense", "enum": [ 10, 20, 30, 100 ], "title": "GetExpense_status" }, "GetExpense_paymentType": { "type": "number", "description": "Payment method", "enum": [ -1, 0, 1, 2, 3, 4, 5, 10, 11 ], "title": "GetExpense_paymentType" }, "GetExpense_amountExcludeVat": { "type": "number", "description": "The amount excluding the vat", "title": "GetExpense_amountExcludeVat" }, "GetExpense_active": { "type": "boolean", "description": "Is the expense currently active or not", "title": "GetExpense_active" }, "GetExpense_remarks": { "type": "string", "description": "Remarks for the expense", "title": "GetExpense_remarks" }, "GetExpense_cancellable": { "type": "boolean", "description": "Is the supplier currently active or not", "title": "GetExpense_cancellable" }, "GetExpense_amountLocal": { "type": "number", "description": "The local amount of the expense", "title": "GetExpense_amountLocal" }, "GetExpense_amountAccounting": { "type": "number", "description": "The amount of accounting", "title": "GetExpense_amountAccounting" }, "GetExpense_vatAccounting": { "type": "number", "description": "The vat amount of accounting", "title": "GetExpense_vatAccounting" }, "GetExpense_creationDate": { "type": "integer", "description": "The creation date of the expense, in UNIX timestamp format", "title": "GetExpense_creationDate" }, "GetExpense_lastUpdateDate": { "type": "integer", "description": "The last update date of the expense, in UNIX timestamp format", "title": "GetExpense_lastUpdateDate" }, "GetExpense": { "type": "object", "additionalProperties": false, "description": "A Single Expense", "properties": { "id": { "$ref": "#/definitions/getExpenseRequest_id" }, "businessType": { "$ref": "#/definitions/GetExpense_businessType" }, "documentType": { "$ref": "#/definitions/GetExpense_documentType" }, "status": { "$ref": "#/definitions/GetExpense_status" }, "paymentType": { "$ref": "#/definitions/GetExpense_paymentType" }, "currency": { "$ref": "#/definitions/Currency" }, "currencyRate": { "$ref": "#/definitions/updateExpenseRequest_currencyRate" }, "amountExcludeVat": { "$ref": "#/definitions/GetExpense_amountExcludeVat" }, "vat": { "$ref": "#/definitions/updateExpenseRequest_vat" }, "amount": { "$ref": "#/definitions/updateExpenseRequest_amount" }, "date": { "$ref": "#/definitions/updateExpenseRequest_date" }, "dueDate": { "$ref": "#/definitions/updateExpenseRequest_dueDate" }, "number": { "$ref": "#/definitions/updateExpenseRequest_number" }, "active": { "$ref": "#/definitions/GetExpense_active" }, "description": { "$ref": "#/definitions/updateExpenseRequest_description" }, "remarks": { "$ref": "#/definitions/GetExpense_remarks" }, "supplier": { "$ref": "#/definitions/Supplier" }, "thumbnail": { "$ref": "#/definitions/GetExpense_thumbnail" }, "url": { "$ref": "#/definitions/GetExpense_url" }, "cancellable": { "$ref": "#/definitions/GetExpense_cancellable" }, "reportingDate": { "$ref": "#/definitions/updateExpenseRequest_reportingDate" }, "accountingClassification": { "$ref": "#/definitions/AccountingClassification" }, "amountLocal": { "$ref": "#/definitions/GetExpense_amountLocal" }, "amountAccounting": { "$ref": "#/definitions/GetExpense_amountAccounting" }, "vatAccounting": { "$ref": "#/definitions/GetExpense_vatAccounting" }, "creationDate": { "$ref": "#/definitions/GetExpense_creationDate" }, "lastUpdateDate": { "$ref": "#/definitions/GetExpense_lastUpdateDate" } }, "title": "GetExpense" }, "updateExpenseResponse": { "oneOf": [ { "$ref": "#/definitions/GetExpense" }, { "$ref": "#/definitions/ErrorResponse" } ], "title": "updateExpenseResponse" }, "searchExpenseDraftsResponse_total": { "type": "number", "description": "The total length of the items that were retrieved", "title": "searchExpenseDraftsResponse_total" }, "searchExpenseDraftsResponse_page": { "type": "number", "description": "The page that was requested to retrieve", "title": "searchExpenseDraftsResponse_page" }, "searchExpenseDraftsResponse_pageSize": { "type": "number", "description": "The page size that was requested", "title": "searchExpenseDraftsResponse_pageSize" }, "searchExpenseDraftsResponse_pages": { "type": "number", "description": "The amount of pages that exist", "title": "searchExpenseDraftsResponse_pages" }, "searchExpensesResponse": { "type": "object", "properties": { "total": { "$ref": "#/definitions/searchExpenseDraftsResponse_total" }, "page": { "$ref": "#/definitions/searchExpenseDraftsResponse_page" }, "pageSize": { "$ref": "#/definitions/searchExpenseDraftsResponse_pageSize" }, "pages": { "$ref": "#/definitions/searchExpenseDraftsResponse_pages" }, "items": { "$ref": "#/definitions/GetExpense" } }, "title": "searchExpensesResponse" }, "searchExpenseDraftsResponse_items_items_fileHash": { "type": "string", "description": "File hash", "title": "searchExpenseDraftsResponse_items_items_fileHash" }, "searchExpenseDraftsResponse_items_items_fileKey": { "type": "string", "description": "Key of the file location", "title": "searchExpenseDraftsResponse_items_items_fileKey" }, "searchExpenseDraftsResponse_items_items": { "type": "object", "additionalProperties": false, "description": "Partial Expense", "properties": { "currency": { "$ref": "#/definitions/Currency" }, "currencyRate": { "$ref": "#/definitions/updateExpenseRequest_currencyRate" }, "vat": { "$ref": "#/definitions/updateExpenseRequest_vat" }, "amount": { "$ref": "#/definitions/updateExpenseRequest_amount" }, "description": { "$ref": "#/definitions/updateExpenseRequest_description" }, "supplier": { "$ref": "#/definitions/Supplier" }, "fileHash": { "$ref": "#/definitions/searchExpenseDraftsResponse_items_items_fileHash" }, "fileKey": { "$ref": "#/definitions/searchExpenseDraftsResponse_items_items_fileKey" } }, "title": "searchExpenseDraftsResponse_items_items" }, "searchExpenseDraftsResponse_items": { "type": "array", "additionalItems": false, "description": "The expense drafts that were found", "items": { "$ref": "#/definitions/searchExpenseDraftsResponse_items_items" }, "title": "searchExpenseDraftsResponse_items" }, "searchExpenseDraftsResponse": { "type": "object", "additionalProperties": false, "required": [ "page", "pageSize" ], "properties": { "total": { "$ref": "#/definitions/searchExpenseDraftsResponse_total" }, "page": { "$ref": "#/definitions/searchExpenseDraftsResponse_page" }, "pageSize": { "$ref": "#/definitions/searchExpenseDraftsResponse_pageSize" }, "pages": { "$ref": "#/definitions/searchExpenseDraftsResponse_pages" }, "items": { "$ref": "#/definitions/searchExpenseDraftsResponse_items" } }, "title": "searchExpenseDraftsResponse" }, "Query": { "type": "object", "title": "Query", "properties": { "getExpense": { "$ref": "#/definitions/GetExpense" }, "updateExpense": { "$ref": "#/definitions/updateExpenseResponse" }, "searchExpenses": { "$ref": "#/definitions/searchExpensesResponse" }, "searchExpenseDrafts": { "$ref": "#/definitions/searchExpenseDraftsResponse" } } }, "getExpenseRequest": { "type": "object", "additionalProperties": false, "required": [ "id" ], "properties": { "id": { "$ref": "#/definitions/getExpenseRequest_id" } }, "title": "getExpenseRequest" }, "updateExpenseRequest": { "type": "object", "additionalProperties": false, "required": [ "id" ], "properties": { "id": { "$ref": "#/definitions/getExpenseRequest_id" }, "paymentType": { "$ref": "#/definitions/updateExpenseRequest_paymentType" }, "currency": { "$ref": "#/definitions/Currency" }, "currencyRate": { "$ref": "#/definitions/updateExpenseRequest_currencyRate" }, "vat": { "$ref": "#/definitions/updateExpenseRequest_vat" }, "amount": { "$ref": "#/definitions/updateExpenseRequest_amount" }, "date": { "$ref": "#/definitions/updateExpenseRequest_date" }, "dueDate": { "$ref": "#/definitions/updateExpenseRequest_dueDate" }, "reportingDate": { "$ref": "#/definitions/updateExpenseRequest_reportingDate" }, "documentType": { "$ref": "#/definitions/updateExpenseRequest_documentType" }, "number": { "$ref": "#/definitions/updateExpenseRequest_number" }, "description": { "$ref": "#/definitions/updateExpenseRequest_description" }, "remarks": { "$ref": "#/definitions/updateExpenseRequest_remarks" }, "supplier": { "$ref": "#/definitions/Supplier" }, "accountingClassification": { "$ref": "#/definitions/AccountingClassification" }, "active": { "$ref": "#/definitions/updateExpenseRequest_active" } }, "title": "updateExpenseRequest" }, "searchExpensesRequest_fromDate": { "type": "string", "description": "Expense that were created after the specified date in the format YYYY-MM-DD", "title": "searchExpensesRequest_fromDate" }, "searchExpensesRequest_toDate": { "type": "string", "description": "Expense that were created until the specified date in the format YYYY-MM-DD", "title": "searchExpensesRequest_toDate" }, "searchExpensesRequest_dueDate": { "type": "string", "description": "Due date of the expense, in the format YYYY-MM-DD", "title": "searchExpensesRequest_dueDate" }, "searchExpensesRequest_description": { "type": "string", "description": "Expense description", "title": "searchExpensesRequest_description" }, "searchExpenseDraftsRequest_supplierId": { "type": "string", "description": "Supplier's ID", "title": "searchExpenseDraftsRequest_supplierId" }, "searchExpenseDraftsRequest_supplierName": { "type": "string", "description": "Supplier's name", "title": "searchExpenseDraftsRequest_supplierName" }, "searchExpensesRequest_number": { "type": "string", "description": "Expense serial number", "title": "searchExpensesRequest_number" }, "searchExpensesRequest_paid": { "type": "boolean", "description": "Filter expenses that are only paid or unpaid, if not added to the request, will return both", "title": "searchExpensesRequest_paid" }, "searchExpensesRequest_reported": { "type": "boolean", "description": "Filter expenses that are only reported or unreported, if not added to the request, will return both", "title": "searchExpensesRequest_reported" }, "searchExpensesRequest_sort": { "type": "string", "description": "The field to sort the results by", "title": "searchExpensesRequest_sort" }, "searchExpensesRequest_minAmount": { "type": "number", "description": "Min amount of the expense", "title": "searchExpensesRequest_minAmount" }, "searchExpensesRequest_maxAmount": { "type": "number", "description": "Max amount of the expense", "title": "searchExpensesRequest_maxAmount" }, "searchExpenseDraftsRequest_page": { "type": "number", "description": "Page requested", "title": "searchExpenseDraftsRequest_page" }, "searchExpenseDraftsRequest_pageSize": { "type": "number", "description": "Results per page", "title": "searchExpenseDraftsRequest_pageSize" }, "searchExpensesRequest": { "type": "object", "additionalProperties": false, "properties": { "fromDate": { "$ref": "#/definitions/searchExpensesRequest_fromDate" }, "toDate": { "$ref": "#/definitions/searchExpensesRequest_toDate" }, "dueDate": { "$ref": "#/definitions/searchExpensesRequest_dueDate" }, "description": { "$ref": "#/definitions/searchExpensesRequest_description" }, "supplierId": { "$ref": "#/definitions/searchExpenseDraftsRequest_supplierId" }, "supplierName": { "$ref": "#/definitions/searchExpenseDraftsRequest_supplierName" }, "number": { "$ref": "#/definitions/searchExpensesRequest_number" }, "paid": { "$ref": "#/definitions/searchExpensesRequest_paid" }, "reported": { "$ref": "#/definitions/searchExpensesRequest_reported" }, "sort": { "$ref": "#/definitions/searchExpensesRequest_sort" }, "minAmount": { "$ref": "#/definitions/searchExpensesRequest_minAmount" }, "maxAmount": { "$ref": "#/definitions/searchExpensesRequest_maxAmount" }, "page": { "$ref": "#/definitions/searchExpenseDraftsRequest_page" }, "pageSize": { "$ref": "#/definitions/searchExpenseDraftsRequest_pageSize" } }, "required": [ "minAmount", "maxAmount", "page", "pageSize" ], "title": "searchExpensesRequest" }, "YYYY-MM-DD": { "type": "string", "description": "Expense drafts that were created after the specified date in the format YYYY-MM-DD", "format": "YYYY-MM-DD", "title": "YYYY-MM-DD" }, "YYYY-MM-DD2": { "type": "string", "description": "Expense drafts that were created until the specified date in the format YYYY-MM-DD", "format": "YYYY-MM-DD", "title": "YYYY-MM-DD" }, "searchExpenseDraftsRequest_description": { "type": "string", "description": "Expense draft description", "title": "searchExpenseDraftsRequest_description" }, "searchExpenseDraftsRequest": { "type": "object", "additionalProperties": false, "required": [], "properties": { "fromDate": { "$ref": "#/definitions/YYYY-MM-DD" }, "toDate": { "$ref": "#/definitions/YYYY-MM-DD2" }, "description": { "$ref": "#/definitions/searchExpenseDraftsRequest_description" }, "supplierId": { "$ref": "#/definitions/searchExpenseDraftsRequest_supplierId" }, "supplierName": { "$ref": "#/definitions/searchExpenseDraftsRequest_supplierName" }, "page": { "$ref": "#/definitions/searchExpenseDraftsRequest_page" }, "pageSize": { "$ref": "#/definitions/searchExpenseDraftsRequest_pageSize" } }, "title": "searchExpenseDraftsRequest" }, "QueryInput": { "type": "object", "title": "QueryInput", "properties": { "getExpense": { "$ref": "#/definitions/getExpenseRequest" }, "updateExpense": { "$ref": "#/definitions/updateExpenseRequest" }, "searchExpenses": { "$ref": "#/definitions/searchExpensesRequest" }, "searchExpenseDrafts": { "$ref": "#/definitions/searchExpenseDraftsRequest" } } }, "_schema": { "type": "object", "title": "_schema", "properties": { "mutation": { "$ref": "#/definitions/Mutation" }, "mutationInput": { "$ref": "#/definitions/MutationInput" }, "query": { "$ref": "#/definitions/Query" }, "queryInput": { "$ref": "#/definitions/QueryInput" } }, "required": [ "query" ] } } }