BeaconX e-Invoice API
  1. B2B e-Invoicing
BeaconX e-Invoice API
  • BeaconX e-Invoice API Documentation
  • API Endpoints
    • B2B e-Invoicing
      • Create Document(s)
        POST
      • Cancel Document
        POST
      • Void Document
        POST
      • Unvoid Document
        POST
      • Create Invoice from Receipt
        POST
      • Check Status
        POST
      • Embed QR Code
        POST
      • Invoice Reversal
        POST
      • Update Reference Number
        POST
    • B2C Receipt
      • Retrieve Receipt
      • Search Receipts
      • Create a Receipt
      • Update existing Receipt
      • Void a Receipt
      • Void Multiple Receipts
      • UnVoid a Receipt
      • Send a Receipt (Email / WhatsApp)
      • Download Receipts Report
      • Create Multiple Receipts (Bulk)
      • Receipt Reversal
      • Update Reference Number
      • Check Status
    • TaxPayer
      • Validate Tax Payer
      • Sync Tax Payer Master List
      • Identity
      • Validate SSM
      • Search TIN
    • Lists
      • Get list of all Classification Codes
  1. B2B e-Invoicing

Create Invoice from Receipt

POST
/einvoices/{reference_number}/create
This API endpoint allows source systems to create an e-Invoice by referencing an existing B2C receipt transaction for the Invoice-level and Item-level information.

Request

Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Path Params

Header Params

Body Params application/json

Example
{
  "buyer": {
    "code": "",
    "id_type": "BRN",
    "tin": "C61901366810",
    "id_number": "201903007118",
    "name": "MEDHURST, GRIMES AND SIPES SDN. BHD.",
    "email": "kendall.purdy@reilly.net",
    "address1": "72684 Murl Light Apt. 668",
    "address2": "",
    "address3": "",
    "city": "Lake Tedfort",
    "postcode": "29311",
    "state": "01",
    "country": "MYS",
    "sst_number": "W10-1060-26389071",
    "phone": "0125168978",
    "membership_id": "MYS",
    "is_foreign": "false"
  },
  "shipping": {
    "code": "",
    "id_type": "",
    "tin": "",
    "id_number": "",
    "name": "",
    "email": "",
    "address1": "",
    "address2": "",
    "address3": "",
    "city": "",
    "postcode": "",
    "state": "",
    "country": "MYS"
  }
}

Request Code Samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://einvoice-api.beaconx.com.my/einvoices/VGSP007362828/create' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
  "buyer": {
    "code": "",
    "id_type": "BRN",
    "tin": "C61901366810",
    "id_number": "201903007118",
    "name": "MEDHURST, GRIMES AND SIPES SDN. BHD.",
    "email": "kendall.purdy@reilly.net",
    "address1": "72684 Murl Light Apt. 668",
    "address2": "",
    "address3": "",
    "city": "Lake Tedfort",
    "postcode": "29311",
    "state": "01",
    "country": "MYS",
    "sst_number": "W10-1060-26389071",
    "phone": "0125168978",
    "membership_id": "MYS",
    "is_foreign": "false"
  },
  "shipping": {
    "code": "",
    "id_type": "",
    "tin": "",
    "id_number": "",
    "name": "",
    "email": "",
    "address1": "",
    "address2": "",
    "address3": "",
    "city": "",
    "postcode": "",
    "state": "",
    "country": "MYS"
  }
}'

Responses

🟢200OK
application/json
Body

Example
{
    "status": "OK",
    "message": "",
    "data": {
        "items": [
            {
                "id": 1,
                "quantity": 0.76,
                "subtotal": 7.65,
                "unit_price": 10.2,
                "description": "CHICKEN THIGH",
                "measurement": "KG",
                "discount_rate": 0,
                "total_excl_tax": 7.65,
                "total_incl_tax": 7.65,
                "discount_amount": 0
            },
            {
                "id": 2,
                "quantity": 1,
                "subtotal": 10.99,
                "unit_price": 16.99,
                "description": "NESTLE CORNFLAKES 800G",
                "measurement": "UNIT",
                "discount_rate": 0.35,
                "total_excl_tax": 10.99,
                "total_incl_tax": 10.99,
                "discount_amount": 6
            }
        ],
        "total": 18.65,
        "pos_id": "05",
        "status": "valid",
        "quantity": 1.76,
        "rounding": 0.01,
        "sst_rate": 0,
        "issued_at": "2024-01-20",
        "sub_total": 18.64,
        "sst_amount": 0,
        "buyer_email": "",
        "buyer_phone": "",
        "outlet_code": "VGSP",
        "currency_code": "MYR",
        "currency_rate": 1,
        "membership_id": "",
        "invoice_number": "VGSP007362828",
        "discount_amount": 6,
        "reference_number": "VGSP007362828",
        "service_charge_rate": 0,
        "service_charge_amount": 0,
        "id": "9b3986b2-8d6f-480e-89f4-74588e8d933a"
    }
}
Modified at 2024-11-04 09:33:28
Previous
Unvoid Document
Next
Check Status
Built with