1. Home
  2. ERPAG
  3. API Script
  4. Get Invoice IDs

Get Invoice IDs

By calling the URL endpoint with the GET method, this endpoint returns a list of all invoice IDs. If you want to get the ID of a specific invoice, you need to define the NUMBER parameter in the URL.

Examples:


1. Get all Invoice IDs (call URL https://api.erpag.com/invoices with GET method)

Result:


2. Get the ID for the Invoice whose NUMBER is INV-004581 (call URL https://api.erpag.com/invoices?number=INV-004581 with GET method)

Result:


Note: Access to this API endpoint is allowed only for selected API User account using the API key and API password in the request header with the key name “Authorization” and key value “Basic base64encoded(api_key:api_password)“, or URL parameters ApiKey and ApiSecret for example https://api.erpag.com/invoices?ApiKey=key_056a9spfg1qubg34e409ee233d&ApiSecret=sec_IKJ4Sc2G8jHfr3sHbxQwEfev-Az-1YaF

BLOCKLY SCRIPT

URL parameter:numberinv_numbernull= setinv_numbertoinv_numberinv_number =Is true OrInvoice numberIsList of ID from Sales ordersWhereScope:AlldocumentsOrder by Numberascendinginv_listResponseType:JSONCode:200 – OKsetinv_listtoifdosetinv_numberto

How can we help?