Plur-e
Developers

Business Central API

Call Business Central through the Plur-e public API — list and run catalogued methods, read-only OData queries, the scope each call needs and the deletions the API always refuses.

Quick answer

GET /bc/methods lists the Business Central methods your key may run; POST /bc/methods/{method} runs one with a parameters body; GET /bc/query/{entity} runs a read-only OData query. Reads need bc:read, writes also bc:write, postings also bc:post. The API uses the Business Central environment and company configured in Developers → AI & MCP → Settings, and never deletes: any method that deletes or removes data answers 403.

Base URL: https://api.plur-e.com/api/public/v1. All calls need bc:read at least and run under the Business Central roles of the key (see API keys).

List the methods

curl -s "https://api.plur-e.com/api/public/v1/bc/methods" \
  -H "Authorization: Bearer <YOUR_API_KEY>"

The answer is an array, ordered by section and name, with only the methods that your roles and scopes allow and that are not deletions:

[
  {
    "name": "GetSalesOrders",
    "section": "bc_sales",
    "kind": "read",
    "needsWarehouseEmployee": false,
    "needsSalesPerson": false,
    "params": [ ]
  }
]
FieldMeaning
nameThe method name to use in the URL
sectionThe area of Business Central the method belongs to
kindread, write or posting
needsWarehouseEmployee, needsSalesPersonThe method uses an ERP code; see ERP codes
paramsThe parameters the method accepts

Run a method

curl -s -X POST "https://api.plur-e.com/api/public/v1/bc/methods/GetSalesOrders" \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{ "parameters": [ { "type": "Order", "pageSize": "", "position": "", "salesPerson": "" } ] }'

The body has one property, parameters: an object, an array of objects, or null when the method takes none. Take the parameter names from params in the list above; the example is illustrative. The answer is:

{ "method": "GetSalesOrders", "result": { } }

result is whatever the method returns. Business Central can take several seconds, so use a generous client timeout. If it does not answer in time the API returns 504 with the code plure_timeout.

Which scope each method needs

Kind of methodScopes the key must have
readbc:read
writebc:read and bc:write
postingbc:read and bc:post

A missing scope answers 403 with error plure_1321. A method that is not in the catalogue answers 404 with the code invalid_method. Postings run immediately and cannot be undone: describe the effect to your users before calling them.

Order of checks

  1. The method exists in the catalogue (404 invalid_method otherwise).
  2. The method is not a deletion (403, error plure_1322).
  3. The key has the scope for the kind of method (403, error plure_1321).
  4. The method is not switched off by Plur-e (503, code tool_disabled).
  5. Roles allow it, and the call runs in Business Central.

Deletions are not available

Business Central never deletes through the API, regardless of scopes or roles. A call that would delete answers 403 with error plure_1322: Business Central method '…' is not available through the API: deletions are not allowed. The call is refused before Business Central is contacted, and the method does not appear in GET /bc/methods.

Refused methods:

  • Any method whose name contains delete or remove, in any letter case. Methods added later that follow this naming are refused automatically. The only exception is BintoBininWhsePhysicalToRemove, which moves stock between bins and deletes nothing.
  • These methods, which delete data under other names: CleanWarehouseBatchAPI and the three methods of the shipment packages whose name starts with Delelete (a historical typo): DeleleteAllPackagesShipmentByWhseDocument, DeleletePackageLineShipmentByKey and DeleletePackageShipmentByKey.

Known deleting methods: DeleteDocument, DeleteItemChildFromWarehouseReceipt, DeleteItemTrackingSpecificationOpenV2, DeleteLPChildFromWarehouseReceipt, DeleteLPFromWarehouseReceiptLine, DeleteLPSingle_FromWarehouseReceiptLine, DeletePurchaseOrderTracking, DeleteSalesLines, DeleteTimeSheetComment, DeleteTransferLines, DeleteTransferOrderTracking, Delete_ItemChild_to_LP_Pallet_From_WR2, Delete_LPChild_to_LP_Pallet_From_WRV2, Delete_LPPallet_FromWarehouseReceiptLine, Delete_LP_FromWarehouseReceiptLineV2, Delete_SalesOrderTracking, Delete_WarehouseInvPhysicalCount and RemoveLPFromWarehousePick.

Two methods are allowed in general but refused when the payload asks for a deletion. Every object of an array payload is checked:

MethodRefused when
UpdateItemClassificationAny line has Action equal to Delete
ConsolidatePhysicalInventoryDeleteSourceBatch is anything other than false

Query entities

bc/query reads Business Central through its standard API and, where installed, an analysis API, with a closed list of entities. It is read-only and needs bc:read plus the query.<entity> line in the key's Business Central role (see Business Central tools for the entity list).

curl -s "https://api.plur-e.com/api/public/v1/bc/query" \
  -H "Authorization: Bearer <YOUR_API_KEY>"

returns the entities the key may read:

[ { "entity": "purchaseInvoices", "permissionEntity": "query.purchaseInvoices", "source": "standard" } ]

source is standard or analysis. Then query one of them:

curl -s -G "https://api.plur-e.com/api/public/v1/bc/query/purchaseInvoices" \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  --data-urlencode "filter=postingDate ge 2026-01-01" \
  --data-urlencode "select=number,vendorName,totalAmountIncludingTax" \
  --data-urlencode "orderBy=postingDate desc" \
  --data-urlencode "pageSize=50" \
  --data-urlencode "count=true"
Query parameterMeaning
filterOData $filter on properties of the entity, up to 1000 characters, no navigation paths
selectComma-separated property names; always pass it to keep responses small
orderByProperty names, each optionally followed by asc or desc
pageSize1 to 200 (default 50)
cursorThe nextCursor of the previous page; filter, select and orderBy are then ignored
counttrue adds totalCount, the number of rows that match the filter
{ "items": [ ], "nextCursor": "…", "totalCount": 128, "note": null }

Follow nextCursor until it is empty. An invalid argument answers 400 with the code bc_query_invalid, a cursor from another entity or company answers 400 with bc_cursor_invalid, and a role without the query.<entity> line answers 403 with the code scope_denied.

Environment and company

The API calls the Business Central environment and company configured in Developers → AI & MCP → Settings. If none is configured the call answers 409 with the code environment_not_configured. To work on another company, change that setting; a request cannot choose it.

Was this page helpful?

On this page