GET
/
expenses
/
{id}
curl -X GET "https://api.contazen.ro/v1/expenses/exp_abc123?expand=supplier,category,user" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json"
{
  "success": true,
  "expense": {
    "id": "exp_abc123",
    "reference": "INV-2024-001",
    "description": "Office supplies purchase including paper, pens, and folders",
    "amount": {
      "total": "238.00",
      "without_vat": "200.00",
      "vat": "38.00",
      "currency": "RON"
    },
    "account_amount": {
      "total": "238.00",
      "without_vat": "200.00",
      "vat": "38.00",
      "currency": "RON"
    },
    "vat_percent": 19,
    "with_vat": true,
    "date": "2024-01-15",
    "due_date": "2024-02-15",
    "paid_date": null,
    "is_paid": false,
    "payment_type": null,
    "status": "unpaid",
    "supplier": {
      "id": "sup_xyz789",
      "name": "Office Depot SRL",
      "cui": "RO12345678",
      "rc": "J40/1234/2020",
      "address": "Str. Exemplu 123, Sector 1",
      "city": "Bucharest",
      "county": "Bucharest",
      "country": "Romania"
    },
    "category": {
      "id": 1,
      "name": "Office Expenses",
      "parent_id": null
    },
    "user": {
      "id": 1,
      "name": "John Doe"
    },
    "attachment": {
      "url": "https://api.contazen.ro/v1/files/download/att_def456",
      "type": "pdf"
    },
    "created_at": "2024-01-15 10:30:00",
    "updated_at": "2024-01-15 10:30:00"
  }
}

Overview

The Retrieve Expense endpoint allows you to get complete details about a specific expense record. You can optionally expand related data such as supplier information, category details, and user information.

Path Parameters

id
string
required
The CzUid of the expense to retrieve

Query Parameters

expand
string
Comma-separated list of related data to include in the response:
  • supplier - Include full supplier details instead of just the ID
  • category - Include full category details instead of just the ID
  • user - Include user information for who created the expense

Response

expense
object
Complete expense object with all details

Error Responses

404 Not Found
The expense with the specified ID does not exist or you don’t have access to it
curl -X GET "https://api.contazen.ro/v1/expenses/exp_abc123?expand=supplier,category,user" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json"
{
  "success": true,
  "expense": {
    "id": "exp_abc123",
    "reference": "INV-2024-001",
    "description": "Office supplies purchase including paper, pens, and folders",
    "amount": {
      "total": "238.00",
      "without_vat": "200.00",
      "vat": "38.00",
      "currency": "RON"
    },
    "account_amount": {
      "total": "238.00",
      "without_vat": "200.00",
      "vat": "38.00",
      "currency": "RON"
    },
    "vat_percent": 19,
    "with_vat": true,
    "date": "2024-01-15",
    "due_date": "2024-02-15",
    "paid_date": null,
    "is_paid": false,
    "payment_type": null,
    "status": "unpaid",
    "supplier": {
      "id": "sup_xyz789",
      "name": "Office Depot SRL",
      "cui": "RO12345678",
      "rc": "J40/1234/2020",
      "address": "Str. Exemplu 123, Sector 1",
      "city": "Bucharest",
      "county": "Bucharest",
      "country": "Romania"
    },
    "category": {
      "id": 1,
      "name": "Office Expenses",
      "parent_id": null
    },
    "user": {
      "id": 1,
      "name": "John Doe"
    },
    "attachment": {
      "url": "https://api.contazen.ro/v1/files/download/att_def456",
      "type": "pdf"
    },
    "created_at": "2024-01-15 10:30:00",
    "updated_at": "2024-01-15 10:30:00"
  }
}

Authorizations

Authorization
string
header
required

Use your API key (sk_live_xxx or sk_test_xxx)

Path Parameters

id
string
required

Expense CzUid

Query Parameters

expand
string

Comma-separated list (supplier,category,user,attachment) - Note: attachment is singular as each expense supports only one attachment

Response

Expense details

success
boolean
data
object
meta
object