---
updatedAt: 2025-07-22T08:47:04.000Z
agentTools:
  projectIndex: https://rivhit-api.readme.io/llms.txt
---

# Document.Details

### Get a Document Details

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "Get a Document Details",
    "version": "1.0.0"
  },
  "paths": {
    "/online/RivhitOnlineAPI.svc/Document.Details": {
      "post": {
        "summary": "Document.Details",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "api_token": {
                    "type": "string",
                    "format": "uuid",
                    "example": "DECD03E5-E35C-41E8-84F7-FBA2FB483928",
                    "description": "Rivhit Merchant API Identifier.\n\n**Default:** No\n",
                    "nullable": false,
                    "deprecated": false
                  },
                  "document_type": {
                    "type": "integer",
                    "example": 2,
                    "description": "Document type.\n\n**Range:** 0 to 999\n**Default:** No\n",
                    "nullable": false,
                    "deprecated": false
                  },
                  "document_number": {
                    "type": "integer",
                    "example": 1914,
                    "description": "Document Number.\n\n**Range:** 0 to 999999\n**Default:** No\n",
                    "nullable": false,
                    "deprecated": false
                  }
                },
                "required": [
                  "api_token",
                  "document_type",
                  "document_number"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success - Document Details Returned",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "error_code": {
                      "type": "integer",
                      "example": 0,
                      "description": "The Response Error/Status Number (0 = Success)."
                    },
                    "client_message": {
                      "type": "string",
                      "example": null,
                      "description": "The Client Error Message."
                    },
                    "debug_message": {
                      "type": "string",
                      "example": null,
                      "description": "The Response Error Message."
                    },
                    "data": {
                      "type": "object",
                      "properties": {
                        "agent_id": {
                          "type": "integer",
                          "description": "Agent Identifier."
                        },
                        "comments": {
                          "type": "string",
                          "description": "The Customer Comments (to print on the invoice)."
                        },
                        "company_address": {
                          "type": "string",
                          "description": "The Merchant Address"
                        },
                        "company_fax": {
                          "type": "string",
                          "description": "The Merchant Fax Number."
                        },
                        "company_id": {
                          "type": "integer",
                          "description": "The Merchant Identifier."
                        },
                        "company_name": {
                          "type": "string",
                          "description": "Name of the Business/Merchant."
                        },
                        "company_phone": {
                          "type": "string",
                          "description": "The Merchant Phone Number."
                        },
                        "confirmation_number": {
                          "type": "integer",
                          "description": "The Confirmation Number."
                        },
                        "country": {
                          "type": "string",
                          "description": "Country of the Business/Merchant."
                        },
                        "crm_user_id": {
                          "type": "integer",
                          "description": "CRM User Id (Set the Document Producer)."
                        },
                        "currency_id": {
                          "type": "integer",
                          "description": "The Item Currency Type."
                        },
                        "customer_address": {
                          "type": "string",
                          "description": "Customer Address."
                        },
                        "customer_city": {
                          "type": "string",
                          "description": "Customer City."
                        },
                        "customer_email": {
                          "type": "string",
                          "format": "email",
                          "description": "Customer email."
                        },
                        "customer_id": {
                          "type": "integer",
                          "description": "Rivhit Customer Identifier."
                        },
                        "customer_id_number": {
                          "type": "integer",
                          "description": "Customer Israeli ID (by Custom Format)."
                        },
                        "customer_name": {
                          "type": "string",
                          "description": "Customer Full Name (First and Last Name)."
                        },
                        "customer_phone": {
                          "type": "string",
                          "description": "Customer Phone Number."
                        },
                        "customer_zipcode": {
                          "type": "integer",
                          "description": "Customer Zip Code."
                        },
                        "discount_amount": {
                          "type": "number",
                          "format": "double",
                          "description": "Discount Amount."
                        },
                        "discount_percent": {
                          "type": "number",
                          "format": "double",
                          "description": "Discount Percentage."
                        },
                        "document_date": {
                          "type": "string",
                          "description": "Document Date (DD/MM/YYYY)."
                        },
                        "document_due_date": {
                          "type": "string",
                          "description": "Document Due Date (DD/MM/YYYY)."
                        },
                        "document_number": {
                          "type": "string",
                          "description": "The Serial Document Number and Type (\"02/000005\")."
                        },
                        "document_total": {
                          "type": "number",
                          "format": "double",
                          "description": "The Document Total Amount in NIS."
                        },
                        "document_total_mtc": {
                          "type": "number",
                          "format": "double",
                          "description": "The Document Total in MTC Currency."
                        },
                        "document_type": {
                          "type": "string",
                          "description": "Document type."
                        },
                        "documnet_time": {
                          "type": "string",
                          "description": "Document Time of Making (HH:MM:SS)."
                        },
                        "exchange_rate": {
                          "type": "number",
                          "format": "double",
                          "description": "Exchange Rate Used for the Document."
                        },
                        "is_cancelled": {
                          "type": "boolean",
                          "description": "Indicates Whether the Document is Cancelled."
                        },
                        "is_closed": {
                          "type": "boolean",
                          "description": "Indicates Whether the Document is Closed."
                        },
                        "items": {
                          "type": "array",
                          "description": "List of Items Included in the Document.",
                          "items": {
                            "type": "object",
                            "properties": {
                              "bruto_price_nis": {
                                "type": "number",
                                "format": "double",
                                "description": "The Item Bruto Price in ILS."
                              },
                              "catalog_number": {
                                "type": "string",
                                "description": "Item Catalog Number (SKU)."
                              },
                              "description": {
                                "type": "string",
                                "description": "Rivhit Item Description."
                              },
                              "discount": {
                                "type": "number",
                                "format": "double",
                                "description": "Discount Value."
                              },
                              "is_closed": {
                                "type": "boolean",
                                "description": "Indicates whether the item is closed."
                              },
                              "item_id": {
                                "type": "integer",
                                "description": "Rivhit Item Identifier."
                              },
                              "line": {
                                "type": "integer",
                                "description": "Line Number of the Item in the Document."
                              },
                              "mtc_code": {
                                "type": "integer",
                                "description": "MTC Code for the Item."
                              },
                              "price_mtc": {
                                "type": "number",
                                "format": "double",
                                "description": "The Item Price in foreign currency (MTC)."
                              },
                              "price_nis": {
                                "type": "number",
                                "format": "double",
                                "description": "The Item Price in ILS."
                              },
                              "quantity": {
                                "type": "number",
                                "format": "double",
                                "description": "The Item Quantity."
                              },
                              "storage_id": {
                                "type": "integer",
                                "description": "The Storage Id Serial Number (Rivhit system)."
                              },
                              "total_line": {
                                "type": "number",
                                "format": "double",
                                "description": "Total Amount for the Item in the Line."
                              }
                            }
                          }
                        },
                        "order": {
                          "type": "string",
                          "description": "The Order Value."
                        },
                        "payments": {
                          "type": "array",
                          "description": "List of Payments Associated with the Document.",
                          "items": {
                            "type": "object",
                            "properties": {
                              "account_number": {
                                "type": "string",
                                "description": "Account Number of the Bank."
                              },
                              "amount": {
                                "type": "number",
                                "format": "double",
                                "description": "Payment Amount."
                              },
                              "bank": {
                                "type": "integer",
                                "description": "Bank Code."
                              },
                              "branch": {
                                "type": "integer",
                                "description": "Bank Branch."
                              },
                              "check_number": {
                                "type": "integer",
                                "description": "Check Number for the Payment."
                              },
                              "details": {
                                "type": "string",
                                "description": "Payment Description."
                              },
                              "due_date": {
                                "type": "string",
                                "description": "Due Date of the Payment (DD/MM/YYYY)."
                              },
                              "line_number": {
                                "type": "integer",
                                "description": "Line Number of the Payment."
                              },
                              "payment_type": {
                                "type": "string",
                                "description": "The Payment Type (Default 1 = Check 2 = Cash 4 = Isracard 5 = Visa 9 = Bank Transfer)."
                              },
                              "payment_type_format": {
                                "type": "integer",
                                "description": "Format of the Payment Type."
                              },
                              "payment_type_id": {
                                "type": "integer",
                                "description": "Payment Type Identifier."
                              }
                            }
                          }
                        },
                        "price_include_vat": {
                          "type": "boolean",
                          "description": "Indicates Whether the Item Price Includes VAT."
                        },
                        "project_id": {
                          "type": "integer",
                          "description": "Project Identifier."
                        },
                        "receipt_total": {
                          "type": "number",
                          "format": "double",
                          "description": "Receipt Total Amount."
                        },
                        "reference": {
                          "type": "integer",
                          "description": "The Reference Value - Will be Saved in the Invoice."
                        },
                        "sort_code": {
                          "type": "integer",
                          "description": "The Sort Code of the Document."
                        },
                        "total_vat": {
                          "type": "number",
                          "format": "double",
                          "description": "The VAT Amount."
                        },
                        "total_without_vat": {
                          "type": "number",
                          "format": "double",
                          "description": "Total Amount Without VAT."
                        },
                        "vat_percent": {
                          "type": "string",
                          "description": "VAT Percentage."
                        }
                      }
                    }
                  }
                },
                "example": {
                  "error_code": 0,
                  "client_message": "",
                  "debug_message": "",
                  "data": {
                    "agent_id": 1,
                    "comments": "this is a test document with payment\r\n\r\nפה זה כל המסמכים 2",
                    "company_address": "הפרחים, תל אביב ",
                    "company_fax": "",
                    "company_id": 123,
                    "company_name": "!!!  עסק לניסיון  !!!!",
                    "company_phone": "03-9999999",
                    "confirmation_number": 0,
                    "country": "",
                    "crm_user_id": null,
                    "currency_id": 1,
                    "customer_address": "Hashalom",
                    "customer_city": "",
                    "customer_email": "alonbrivhit@gmail.com",
                    "customer_id": 20010,
                    "customer_id_number": 123456790,
                    "customer_name": "Israeli Moshe",
                    "customer_phone": "0501234567",
                    "customer_zipcode": 123456,
                    "discount_amount": -0.04,
                    "discount_percent": 0.47,
                    "document_date": "10/02/2026",
                    "document_due_date": "15/02/2026",
                    "document_number": "02/001914",
                    "document_total": 9.95,
                    "document_total_mtc": 0,
                    "document_type": "חשבונית מס קבלה",
                    "documnet_time": "11:00:00",
                    "exchange_rate": 0,
                    "is_cancelled": false,
                    "is_closed": false,
                    "items": [
                      {
                        "bruto_price_nis": 10,
                        "catalog_number": "",
                        "description": "Sample Item",
                        "discount": 0,
                        "is_closed": false,
                        "item_id": 0,
                        "line": 1,
                        "mtc_code": 1,
                        "price_mtc": 0,
                        "price_nis": 10,
                        "quantity": 1,
                        "storage_id": 1,
                        "total_line": 10
                      }
                    ],
                    "order": "zy321",
                    "payments": [
                      {
                        "account_number": "0",
                        "amount": 9.95,
                        "bank": null,
                        "branch": null,
                        "check_number": null,
                        "details": "תשלום ",
                        "due_date": "10/02/2026",
                        "line_number": 1,
                        "payment_type": "מזומן",
                        "payment_type_format": 0,
                        "payment_type_id": 0
                      }
                    ],
                    "price_include_vat": true,
                    "project_id": 1,
                    "receipt_total": 9.95,
                    "reference": 12345,
                    "sort_code": 200,
                    "total_vat": 1.52,
                    "total_without_vat": 8.47,
                    "vat_percent": "18.00%"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Request Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "string",
                      "example": "Request Error"
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "error_code": {
                      "type": "integer",
                      "example": 0,
                      "description": "Error code of the response."
                    },
                    "client_message": {
                      "type": "string",
                      "example": "",
                      "description": "The Client Error Message."
                    },
                    "debug_message": {
                      "type": "string",
                      "example": "",
                      "description": "The Response Error Message."
                    },
                    "data": {
                      "type": "array",
                      "example": null,
                      "description": "Error Data"
                    }
                  }
                },
                "example": {
                  "error_code": -2,
                  "client_message": "לא נמצאו נתונים",
                  "debug_message": "-2 : NO_DATA_FOUND",
                  "data": null
                }
              }
            }
          }
        }
      }
    }
  },
  "servers": [
    {
      "url": "https://api.rivhit.co.il/"
    }
  ]
}
```