Get One Invoice
GET/api/accounting/invoice/:id
Get One Invoice
Request
Path Parameters
id integerrequired
Header Parameters
X-Company-Slug stringrequired
Responses
- 200
Successful response
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
Array [
]
Array [
]
number stringnullablerequired
order_number stringnullablerequired
currency CurrencyEnum (string)required
Possible values: [EUR
, USD
, GBP
, TRY
]
status DocumentStatusEnum (string)required
Possible values: [draft
, sent
, paid
]
contact_id numbernullablerequired
Geçerli bir company_id olması gerekiyor
contact_name stringnullablerequired
contact_tax_number stringnullablerequired
contact_phone numbernullablerequired
contact_email stringnullablerequired
contact_address stringnullablerequired
issued_at timenullablerequired
due_at timenullablerequired
type DocumentTypeEnum (string)nullablerequired
Possible values: [invoice
, bill
]
Eğer invoice isteniyorsa invoice, bill isteniyorsa bill
discount_type DiscountTypeEnum (string)nullablerequired
Possible values: [fix
, percent
]
discount stringnullablerequired
created_by_id stringnullablerequired
created_at timerequired
updated_at stringrequired
id stringrequired
total numbernullablerequired
history
object[]
id stringrequired
document_id stringrequired
created_by_id stringrequired
status stringrequired
description stringrequired
created_at date-time
updated_at date-time
transactions
get_transaction_single[]
id string
document_id stringnullable
account_id string
contact_id stringnullable
created_by_id string
amount numbernullable
currency CurrencyEnum (string)
Possible values: [EUR
, USD
, GBP
, TRY
]
type TransactionTypeEnum (string)
Possible values: [income
, expense
, order
, reservation
]
reference stringnullable
description stringnullable
paid_at string
created_at string
updated_at string
order_id stringnullable
reservation_id stringnullable
tips numbernullable
discount numbernullable
payment_method TransactionPaymentMethodEnums (string)
Possible values: [cash
, credit_card
, bank_transfer
, qr
]
account
object
id stringrequired
created_by_id stringrequired
name stringrequired
number stringnullablerequired
currency CurrencyEnum (string)required
Possible values: [EUR
, USD
, GBP
, TRY
]
bank_name stringnullablerequired
bank_phone stringnullablerequired
bank_address stringnullablerequired
enabled booleanrequired
created_at date-timerequired
updated_at date-timerequired
deleted_at date-timenullablerequired
total integerrequired
items
item_res[]
id stringnullablerequired
document_id stringrequired
name stringrequired
description stringnullablerequired
sku stringnullablerequired
quantity numberrequired
price numberrequired
discount numbernullablerequired
total numbernullablerequired
created_at stringrequired
updated_at stringrequired
tax_id numbernullablerequired
{
"number": "string",
"order_number": "string",
"currency": "EUR",
"status": "draft",
"contact_id": 0,
"contact_name": "string",
"contact_tax_number": "string",
"contact_phone": 0,
"contact_email": "string",
"contact_address": "string",
"issued_at": "string",
"due_at": "string",
"type": "invoice",
"discount_type": "fix",
"discount": "string",
"created_by_id": "string",
"created_at": "string",
"updated_at": "string",
"id": "string",
"total": 0,
"history": [
{
"id": "9",
"document_id": "4",
"created_by_id": "1",
"status": "draft",
"description": "accounting.invoice.created",
"created_at": "2024-07-18T23:41:34.130+03:00",
"updated_at": "2024-07-18T23:41:34.130+03:00"
}
],
"transactions": [
{
"id": "string",
"document_id": "string",
"account_id": "string",
"contact_id": "string",
"created_by_id": "string",
"amount": 0,
"currency": "EUR",
"type": "income",
"reference": "string",
"description": "string",
"paid_at": "string",
"created_at": "string",
"updated_at": "string",
"order_id": "string",
"reservation_id": "string",
"tips": 0,
"discount": 0,
"payment_method": "cash",
"account": {
"id": "2",
"created_by_id": "1",
"name": "YAPI KREDI (KMH)",
"number": "TR3284972923473",
"currency": "EUR",
"bank_name": "yapı kredi",
"bank_phone": 2521111111,
"bank_address": "İstanbul",
"enabled": true,
"created_at": "2024-07-16T20:35:36.937+03:00",
"updated_at": "2024-07-16T20:35:36.937+03:00",
"deleted_at": "2024-07-16T20:35:36.937+03:00",
"total": 0
}
}
],
"items": [
{
"id": "string",
"document_id": "string",
"name": "string",
"description": "string",
"sku": "string",
"quantity": 0,
"price": 0,
"discount": 0,
"total": 0,
"created_at": "string",
"updated_at": "string",
"tax_id": 0
}
]
}
Loading...