Integrations / Precoro
Precoro
Procurement in Precoro: purchase orders, requisitions, invoices, suppliers and approvals.
8 actions
API key
7 read1 write
Calls api.precoro.com
Connect
const conn = await setu.connections.initiate({ userId: "user_1", toolkit: "precoro" });
console.log(conn.connectUrl); // show this to your user
await conn.waitUntilActive();Permissions requested
This toolkit uses a single credential and requests no scopes.
Actions
Approve documentwriteprecoro.approve_documentApprove a purchase requisition, purchase order, invoice, expense or warehouse request as the user who owns the API key. Approval moves money, so only do this when asked.
| Input | Type | Description | |
|---|---|---|---|
document_alias | string | Required | Type of document |
idn | string | Required | Document IDN |
await setu.execute({
userId: "user_1",
action: "precoro.approve_document",
input: {
"document_alias": "<document_alias>",
"idn": "<idn>"
},
});Get purchase orderreadprecoro.get_purchase_orderGet one purchase order by its IDN (the number shown in Precoro), including its line items and approval steps.
| Input | Type | Description | |
|---|---|---|---|
idn | string | Required | Purchase order IDN, for example 2 |
await setu.execute({
userId: "user_1",
action: "precoro.get_purchase_order",
input: {
"idn": "<idn>"
},
});Get supplierreadprecoro.get_supplierGet one supplier by ID: contact details, currencies, payment terms and status.
| Input | Type | Description | |
|---|---|---|---|
id | integer | Required | Supplier ID |
await setu.execute({
userId: "user_1",
action: "precoro.get_supplier",
input: {
"id": 1
},
});List invoicesreadprecoro.list_invoicesList supplier invoices, optionally only those changed since a date.
| Input | Type | Description | |
|---|---|---|---|
modified_since | string | Optional | Only records created or updated since this date-time, like 2025-01-01T00:00:00 |
per_page | integer | Optional | Page size: 10, 20, 50, 100 or 200 |
page | integer | Optional | Page number, starting at 1 |
await setu.execute({
userId: "user_1",
action: "precoro.list_invoices",
input: {},
});List purchase ordersreadprecoro.list_purchase_ordersList purchase orders (without line items), newest changes first when filtered by modified date. Status 2 means approved.
| Input | Type | Description | |
|---|---|---|---|
modified_since | string | Optional | Only records created or updated since this date-time, like 2025-01-01T00:00:00 |
per_page | integer | Optional | Page size: 10, 20, 50, 100 or 200 |
page | integer | Optional | Page number, starting at 1 |
await setu.execute({
userId: "user_1",
action: "precoro.list_purchase_orders",
input: {},
});List purchase requisitionsreadprecoro.list_purchase_requisitionsList purchase requisitions (requests to buy), optionally only those changed since a date.
| Input | Type | Description | |
|---|---|---|---|
modified_since | string | Optional | Only records created or updated since this date-time, like 2025-01-01T00:00:00 |
per_page | integer | Optional | Page size: 10, 20, 50, 100 or 200 |
page | integer | Optional | Page number, starting at 1 |
await setu.execute({
userId: "user_1",
action: "precoro.list_purchase_requisitions",
input: {},
});List suppliersreadprecoro.list_suppliersList suppliers with currency and status, optionally only those changed since a date.
| Input | Type | Description | |
|---|---|---|---|
modified_since | string | Optional | Only records created or updated since this date-time, like 2025-01-01T00:00:00 |
per_page | integer | Optional | Page size: 10, 20, 50, 100 or 200 |
page | integer | Optional | Page number, starting at 1 |
await setu.execute({
userId: "user_1",
action: "precoro.list_suppliers",
input: {},
});List usersreadprecoro.list_usersList Precoro users with their email, name and position.
No input.
await setu.execute({
userId: "user_1",
action: "precoro.list_users",
input: {},
});