Introduction
This documentation aims to provide all the information you need to work with our API.
<aside>As you scroll, you'll see code examples for working with the API in different programming languages in the dark area to the right (or as part of the content on mobile).
You can switch the language used with the tabs at the top right (or from the nav menu at the top left on mobile).</aside>
Authenticating requests
To authenticate requests, include an Authorization header with the value "Bearer your-token".
All authenticated endpoints are marked with a requires authentication badge in the documentation below.
ACL
Endpoints for managing roles and permissions.
Roles
Endpoints for managing roles.
List
requires authentication role index
List roles.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/acl/roles?q=Role+name" \
--header "Authorization: Bearer c3gh5D6kEdV8evaZ4b1f6Pa" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/roles"
);
const params = {
"q": "Role name",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer c3gh5D6kEdV8evaZ4b1f6Pa",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "b5abc089-4a86-3446-9c3e-9ea22dfbd683",
"name": "reprehenderit-6b085ba007879",
"display_name": "Voluptate quia maxime neque sit excepturi et odio.",
"permissions_count": null
},
{
"id": "956d9435-5f19-3738-b1e4-1bca1b55a1b6",
"name": "eaque-6b085ba00b74e",
"display_name": "Dicta in tenetur qui aut inventore quasi id voluptates.",
"permissions_count": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create
requires authentication role store
Create a new role.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/acl/roles" \
--header "Authorization: Bearer VgD3d56a6Pcha84ZfbE1ekv" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"display_name\": \"Example Name\",
\"permissions\": [
\"d68a4292-1df5-309d-ac0c-983a3fbd0d15\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/roles"
);
const headers = {
"Authorization": "Bearer VgD3d56a6Pcha84ZfbE1ekv",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"display_name": "Example Name",
"permissions": [
"d68a4292-1df5-309d-ac0c-983a3fbd0d15"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update
requires authentication role update
Update a role.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/acl/roles/1" \
--header "Authorization: Bearer Eh4aefVgZac63bkD5d81Pv6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"display_name\": \"Example Name\",
\"permissions\": [
\"847afbb1-7061-3d31-a162-72e9fb20811e\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/roles/1"
);
const headers = {
"Authorization": "Bearer Eh4aefVgZac63bkD5d81Pv6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"display_name": "Example Name",
"permissions": [
"847afbb1-7061-3d31-a162-72e9fb20811e"
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show
requires authentication role show
Show a role.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/acl/roles/1" \
--header "Authorization: Bearer 8gPhbav3fD4d6Za1kcV65Ee" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/roles/1"
);
const headers = {
"Authorization": "Bearer 8gPhbav3fD4d6Za1kcV65Ee",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "50709b42-d56e-3ea3-ae43-72c162685af6",
"name": "ipsam-6b085ba0193fc",
"display_name": "Odit distinctio culpa quis.",
"permissions_count": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Role Permissions
requires authentication role show
List permissions associated with a role.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/acl/roles/1/permissions" \
--header "Authorization: Bearer ZaDd8P34bv6hEa1ek5cf6gV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/roles/1/permissions"
);
const headers = {
"Authorization": "Bearer ZaDd8P34bv6hEa1ek5cf6gV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": null,
"name": "ut",
"display_name": "Eos impedit esse omnis repellendus est voluptate."
},
{
"id": null,
"name": "velit",
"display_name": "Porro iure incidunt repellat aut labore dignissimos."
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete
requires authentication role delete
Delete a role.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/acl/roles/1" \
--header "Authorization: Bearer c3EV4PagfeZ1Dhk66dav8b5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/roles/1"
);
const headers = {
"Authorization": "Bearer c3EV4PagfeZ1Dhk66dav8b5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Permissions
Endpoints for managing permissions.
List
requires authentication permission index
List permissions.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/acl/permissions?q=Permission+name" \
--header "Authorization: Bearer ahgb64fZVvPD38Eac651ekd" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/permissions"
);
const params = {
"q": "Permission name",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer ahgb64fZVvPD38Eac651ekd",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": null,
"name": "ipsum",
"display_name": "Ab asperiores eum hic saepe et necessitatibus maiores."
},
{
"id": null,
"name": "aut",
"display_name": "Voluptas et quis nemo natus quia."
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create
requires authentication permission store
Create a new permission.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/acl/permissions" \
--header "Authorization: Bearer hg4e8PV563ZDvfbac1kad6E" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"display_name\": \"Example Name\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/permissions"
);
const headers = {
"Authorization": "Bearer hg4e8PV563ZDvfbac1kad6E",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"display_name": "Example Name"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update
requires authentication permission update
Update a permission.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/acl/permissions/1" \
--header "Authorization: Bearer dgDkeZ864VhacaE63Pv1bf5" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"display_name\": \"Example Name\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/permissions/1"
);
const headers = {
"Authorization": "Bearer dgDkeZ864VhacaE63Pv1bf5",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"display_name": "Example Name"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show
requires authentication permission show
Show a permission.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/acl/permissions/1" \
--header "Authorization: Bearer 3EkVhvg6fa1DaPc6eZ4d5b8" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/permissions/1"
);
const headers = {
"Authorization": "Bearer 3EkVhvg6fa1DaPc6eZ4d5b8",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": null,
"name": "et",
"display_name": "In dolores et nobis et quidem repellendus illum."
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete
requires authentication permission delete
Delete a permission.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/acl/permissions/1" \
--header "Authorization: Bearer 1V465PEcZhkga6D3vdb8afe" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/acl/permissions/1"
);
const headers = {
"Authorization": "Bearer 1V465PEcZhkga6D3vdb8afe",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Accounts Payable Receivable
Endpoints for accounts payable receivable
List reminders for accounts payable receivable
requires authentication accounts-payable-receivable reminder
List reminders for accounts payable receivable that are about to expire soon
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/reminders" \
--header "Authorization: Bearer PZ8v5egda61ckfD4Eah6Vb3" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/reminders"
);
const headers = {
"Authorization": "Bearer PZ8v5egda61ckfD4Eah6Vb3",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "7524d0f3-f4d5-30c3-8b1b-967e8e2a9385",
"code": null,
"type": "saída",
"payment_method": "boleto",
"amount": 4279.58,
"due_date": "2026-12-12T03:00:00.000000Z",
"status": null,
"payment_date": null,
"protest_date": null,
"paid_amount": null,
"interest_amount": null,
"penalty_amount": null,
"notary_fee_amount": null,
"description": "Voluptas id alias reprehenderit accusamus dolorem quo rerum quasi quaerat officia repudiandae.",
"is_recurring": null,
"recurrence_config": null,
"parent_id": null,
"recurrence_order": 1,
"total_recurrences": null,
"children_count": 0,
"remaining_recurrences": null,
"has_children": false,
"field1": "tempore",
"field2": 74,
"field3": false,
"notes": "Iusto et ratione saepe quam nemo repudiandae.",
"created_at": null,
"updated_at": null
},
{
"id": "7943ec75-304d-3ca0-a922-248ce9c77f1b",
"code": null,
"type": "entrada",
"payment_method": "cheque",
"amount": 8225.2,
"due_date": "2026-12-22T03:00:00.000000Z",
"status": null,
"payment_date": null,
"protest_date": null,
"paid_amount": null,
"interest_amount": null,
"penalty_amount": null,
"notary_fee_amount": null,
"description": "Eaque exercitationem dolorem sequi velit velit totam.",
"is_recurring": null,
"recurrence_config": null,
"parent_id": null,
"recurrence_order": 1,
"total_recurrences": null,
"children_count": 0,
"remaining_recurrences": null,
"has_children": false,
"field1": "et",
"field2": 33,
"field3": false,
"notes": "Enim quia ea voluptatum iure et.",
"created_at": null,
"updated_at": null
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Mark reminders as read
requires authentication accounts-payable-receivable reminder
Mark reminders for accounts payable receivable as read
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/reminders/mark-as-read?items[]=harum" \
--header "Authorization: Bearer Da3P6EZf58d6beva4Vkh1cg" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/reminders/mark-as-read"
);
const params = {
"items[0]": "harum",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer Da3P6EZf58d6beva4Vkh1cg",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get protest summary
requires authentication accounts-payable-receivable index
Get summary of accounts with protest status
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/protests/summary" \
--header "Authorization: Bearer Ph4ac5a3VkdZ6Egvb1D8ef6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/protests/summary"
);
const headers = {
"Authorization": "Bearer Ph4ac5a3VkdZ6Egvb1D8ef6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"to_protest_count": "integer",
"protested_count": "integer",
"protesting_today_count": "integer",
"total_protest_amount": "float"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List protested accounts
requires authentication accounts-payable-receivable index
List accounts with protest date that are not paid/canceled
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/protests?sort_by=created_at&sort_desc=1&page=1&per_page=10&q=Salary&code=CPR-000123&type=entrada&customers[]=ea&suppliers[]=explicabo&works[]=modi&cost_centers[]=ad&statuses[]=a+protestar&payment_method=cheque&date_start=2023-01-01&date_end=2023-12-31&protest_date_start=2026-11-26T13%3A17%3A36&protest_date_end=2026-11-26T13%3A17%3A36&has_protest=1&has_children=1&is_recurring=1" \
--header "Authorization: Bearer Zk5hgfd834eVbaPD1Ev6ca6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/protests"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "10",
"q": "Salary",
"code": "CPR-000123",
"type": "entrada",
"customers[0]": "ea",
"suppliers[0]": "explicabo",
"works[0]": "modi",
"cost_centers[0]": "ad",
"statuses[0]": "a protestar",
"payment_method": "cheque",
"date_start": "2023-01-01",
"date_end": "2023-12-31",
"protest_date_start": "2026-11-26T13:17:36",
"protest_date_end": "2026-11-26T13:17:36",
"has_protest": "1",
"has_children": "1",
"is_recurring": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer Zk5hgfd834eVbaPD1Ev6ca6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "12cca440-db93-3ec6-affa-f132b61b2d0a",
"code": null,
"type": "entrada",
"payment_method": "cheque",
"amount": 7333.41,
"due_date": "2026-12-22T03:00:00.000000Z",
"status": null,
"payment_date": null,
"protest_date": null,
"paid_amount": null,
"interest_amount": null,
"penalty_amount": null,
"notary_fee_amount": null,
"description": "Iure voluptatem non possimus aut illo vitae velit ullam facere quod.",
"is_recurring": null,
"recurrence_config": null,
"parent_id": null,
"recurrence_order": 1,
"total_recurrences": null,
"children_count": 0,
"remaining_recurrences": null,
"has_children": false,
"field1": "quia",
"field2": 28,
"field3": true,
"notes": "Expedita explicabo aperiam deleniti enim.",
"created_at": null,
"updated_at": null
},
{
"id": "20a77d75-d5e7-39b5-96f8-0163ec1a5db4",
"code": null,
"type": "entrada",
"payment_method": "boleto",
"amount": 9781.32,
"due_date": "2026-12-09T03:00:00.000000Z",
"status": null,
"payment_date": null,
"protest_date": null,
"paid_amount": null,
"interest_amount": null,
"penalty_amount": null,
"notary_fee_amount": null,
"description": "Aut fugiat asperiores quibusdam qui pariatur sed repudiandae beatae assumenda in.",
"is_recurring": null,
"recurrence_config": null,
"parent_id": null,
"recurrence_order": 1,
"total_recurrences": null,
"children_count": 0,
"remaining_recurrences": null,
"has_children": false,
"field1": "est",
"field2": 4,
"field3": false,
"notes": "Hic voluptatum quia reprehenderit dolores.",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List accounts payable receivable
requires authentication accounts-payable-receivable index
List all accounts payable receivable
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable?sort_by=created_at&sort_desc=1&page=1&per_page=10&q=Salary&code=CPR-000123&type=entrada&customers[]=dolores&suppliers[]=culpa&works[]=quia&cost_centers[]=sunt&statuses[]=a+protestar&payment_method=cheque&date_start=2023-01-01&date_end=2023-12-31&protest_date_start=2026-11-26T13%3A17%3A36&protest_date_end=2026-11-26T13%3A17%3A36&has_protest=1&has_children=1&is_recurring=1" \
--header "Authorization: Bearer 18P53Z4b6vcVa6EedfhgDak" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "10",
"q": "Salary",
"code": "CPR-000123",
"type": "entrada",
"customers[0]": "dolores",
"suppliers[0]": "culpa",
"works[0]": "quia",
"cost_centers[0]": "sunt",
"statuses[0]": "a protestar",
"payment_method": "cheque",
"date_start": "2023-01-01",
"date_end": "2023-12-31",
"protest_date_start": "2026-11-26T13:17:36",
"protest_date_end": "2026-11-26T13:17:36",
"has_protest": "1",
"has_children": "1",
"is_recurring": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 18P53Z4b6vcVa6EedfhgDak",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "207fd9c3-4032-31ff-8d19-bbee84fa3464",
"code": null,
"type": "entrada",
"payment_method": "boleto",
"amount": 2524.74,
"due_date": "2026-12-10T03:00:00.000000Z",
"status": null,
"payment_date": null,
"protest_date": null,
"paid_amount": null,
"interest_amount": null,
"penalty_amount": null,
"notary_fee_amount": null,
"description": "Saepe tempora quam cumque officiis similique eum aut architecto dignissimos unde amet neque.",
"is_recurring": null,
"recurrence_config": null,
"parent_id": null,
"recurrence_order": 1,
"total_recurrences": null,
"children_count": 0,
"remaining_recurrences": null,
"has_children": false,
"field1": "esse",
"field2": 3,
"field3": true,
"notes": "Dolorum dicta non ut et. Ut eligendi a delectus.",
"created_at": null,
"updated_at": null
},
{
"id": "fd096015-01e5-3d27-9111-dfc4c7539203",
"code": null,
"type": "entrada",
"payment_method": "cheque",
"amount": 676.55,
"due_date": "2026-12-24T03:00:00.000000Z",
"status": null,
"payment_date": null,
"protest_date": null,
"paid_amount": null,
"interest_amount": null,
"penalty_amount": null,
"notary_fee_amount": null,
"description": "Non dolorum eum dolor quo voluptatem illum consequuntur maxime blanditiis.",
"is_recurring": null,
"recurrence_config": null,
"parent_id": null,
"recurrence_order": 1,
"total_recurrences": null,
"children_count": 0,
"remaining_recurrences": null,
"has_children": false,
"field1": "sit",
"field2": 60,
"field3": true,
"notes": "Eveniet delectus rerum magnam porro.",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create accounts payable receivable
requires authentication accounts-payable-receivable store
Create a new accounts payable receivable
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable" \
--header "Authorization: Bearer 1Zkh3a6fcE4eVDbv8d6gaP5" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"type\": \"Example Type\",
\"payment_method\": \"Example Payment method\",
\"due_date\": \"2024-01-01\",
\"amount\": 1,
\"description\": \"Example Description\",
\"supplier_id\": \"e5a23ae2-7591-3cd9-9dc9-67ef26e85882\",
\"customer_id\": \"c850e246-bc03-3f2c-b994-4b225a9a1fdd\",
\"work_id\": \"b2342b99-18f5-3a7f-9ab7-8be83633b7ec\",
\"cost_center_id\": \"8c9c83ad-5b97-3c65-9c75-e5cb26ac3039\",
\"status\": \"Example Status\",
\"protest_date\": \"2024-01-01\",
\"bank_account_id\": \"801ca00e-b040-3781-a24d-7b7c017e9d80\",
\"custom_fields\": [
\"example1\",
\"example2\"
],
\"is_recurring\": true,
\"recurrence_config\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"frequency_type\": \"Example Recurrence config frequency type\",
\"frequency_value\": 1,
\"end_date\": \"2024-01-01\",
\"max_occurrences\": 1,
\"generation_days_ahead\": 1
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable"
);
const headers = {
"Authorization": "Bearer 1Zkh3a6fcE4eVDbv8d6gaP5",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"type": "Example Type",
"payment_method": "Example Payment method",
"due_date": "2024-01-01",
"amount": 1,
"description": "Example Description",
"supplier_id": "e5a23ae2-7591-3cd9-9dc9-67ef26e85882",
"customer_id": "c850e246-bc03-3f2c-b994-4b225a9a1fdd",
"work_id": "b2342b99-18f5-3a7f-9ab7-8be83633b7ec",
"cost_center_id": "8c9c83ad-5b97-3c65-9c75-e5cb26ac3039",
"status": "Example Status",
"protest_date": "2024-01-01",
"bank_account_id": "801ca00e-b040-3781-a24d-7b7c017e9d80",
"custom_fields": [
"example1",
"example2"
],
"is_recurring": true,
"recurrence_config": {
"0": "example1",
"1": "example2",
"frequency_type": "Example Recurrence config frequency type",
"frequency_value": 1,
"end_date": "2024-01-01",
"max_occurrences": 1,
"generation_days_ahead": 1
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Import NFe installments
requires authentication accounts-payable-receivable import-nfe
Gera contas a pagar para as parcelas selecionadas de uma nota fiscal. A obra é opcional: quando omitida, só é herdada se a NF tiver exatamente uma obra vinculada.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/import-nfe" \
--header "Authorization: Bearer bP58dVe6Zkghaf34c1vD6aE" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"fiscal_document_id\": \"minima\",
\"installment_ids\": [
\"dolor\"
],
\"payment_method\": \"outro\",
\"work_id\": \"perferendis\",
\"cost_center_id\": \"quasi\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/import-nfe"
);
const headers = {
"Authorization": "Bearer bP58dVe6Zkghaf34c1vD6aE",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"fiscal_document_id": "minima",
"installment_ids": [
"dolor"
],
"payment_method": "outro",
"work_id": "perferendis",
"cost_center_id": "quasi"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string",
"total": "integer"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get account history
requires authentication accounts-payable-receivable show
Get the activity log history for an account payable receivable
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/numquam/history" \
--header "Authorization: Bearer 56hP6EbZevcVa41Dg38fdak" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/numquam/history"
);
const headers = {
"Authorization": "Bearer 56hP6EbZevcVa41Dg38fdak",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get accounts payable receivable
requires authentication accounts-payable-receivable show
Get an accounts payable receivable
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/neque" \
--header "Authorization: Bearer D3Z164cdhaafbV8k5egvP6E" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/neque"
);
const headers = {
"Authorization": "Bearer D3Z164cdhaafbV8k5egvP6E",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "41169631-f03e-3c32-a445-cc7c6ad55aaf",
"code": null,
"type": "entrada",
"payment_method": "cheque",
"amount": 957.34,
"due_date": "2026-12-06T03:00:00.000000Z",
"status": null,
"payment_date": null,
"protest_date": null,
"paid_amount": null,
"interest_amount": null,
"penalty_amount": null,
"notary_fee_amount": null,
"description": "Unde qui expedita animi blanditiis reprehenderit libero consequatur voluptates quo qui aut est beatae.",
"is_recurring": null,
"recurrence_config": null,
"parent_id": null,
"recurrence_order": 1,
"total_recurrences": null,
"children_count": 0,
"remaining_recurrences": null,
"has_children": false,
"field1": "rem",
"field2": 28,
"field3": true,
"notes": "Dolorum repellat quos voluptatem ea quia ad sint.",
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update accounts payable receivable
requires authentication accounts-payable-receivable update
Update an accounts payable receivable
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/amet" \
--header "Authorization: Bearer 36vc5fk14aVa86DhgedPZbE" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"type\": \"Example Type\",
\"payment_method\": \"Example Payment method\",
\"due_date\": \"2024-01-01\",
\"amount\": 1,
\"description\": \"Example Description\",
\"supplier_id\": \"91575613-5367-3d63-b703-cde063547ea3\",
\"customer_id\": \"aa6f8896-fc6a-3a17-aa7e-be586810af6c\",
\"work_id\": \"eee984d4-0993-3d94-82ea-2ffe6bdece5d\",
\"cost_center_id\": \"ed36c27c-14cc-3eb7-a235-74d7fe088a4e\",
\"status\": \"Example Status\",
\"payment_date\": \"2024-01-01\",
\"protest_date\": \"2024-01-01\",
\"paid_amount\": 1,
\"interest_amount\": 1,
\"penalty_amount\": 1,
\"notary_fee_amount\": 1,
\"bank_account_id\": \"d84b55b6-a94e-3ad2-a92a-b1edc0d141e6\",
\"custom_fields\": [
\"example1\",
\"example2\"
],
\"is_recurring\": true,
\"recurrence_config\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"frequency_type\": \"Example Recurrence config frequency type\",
\"frequency_value\": 1,
\"end_date\": \"2024-01-01\",
\"max_occurrences\": 1,
\"generation_days_ahead\": 1
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/amet"
);
const headers = {
"Authorization": "Bearer 36vc5fk14aVa86DhgedPZbE",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"type": "Example Type",
"payment_method": "Example Payment method",
"due_date": "2024-01-01",
"amount": 1,
"description": "Example Description",
"supplier_id": "91575613-5367-3d63-b703-cde063547ea3",
"customer_id": "aa6f8896-fc6a-3a17-aa7e-be586810af6c",
"work_id": "eee984d4-0993-3d94-82ea-2ffe6bdece5d",
"cost_center_id": "ed36c27c-14cc-3eb7-a235-74d7fe088a4e",
"status": "Example Status",
"payment_date": "2024-01-01",
"protest_date": "2024-01-01",
"paid_amount": 1,
"interest_amount": 1,
"penalty_amount": 1,
"notary_fee_amount": 1,
"bank_account_id": "d84b55b6-a94e-3ad2-a92a-b1edc0d141e6",
"custom_fields": [
"example1",
"example2"
],
"is_recurring": true,
"recurrence_config": {
"0": "example1",
"1": "example2",
"frequency_type": "Example Recurrence config frequency type",
"frequency_value": 1,
"end_date": "2024-01-01",
"max_occurrences": 1,
"generation_days_ahead": 1
}
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete accounts payable receivable
requires authentication accounts-payable-receivable delete
Delete an accounts payable receivable
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/odio" \
--header "Authorization: Bearer 6Zk6DfaEvcPh43Vgd1ea58b" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/accounts-payable-receivable/odio"
);
const headers = {
"Authorization": "Bearer 6Zk6DfaEvcPh43Vgd1ea58b",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Authentication
Endpoints for authentication
Login
No specific permission required
Login with email and password
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/auth/login" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"email\": \"lrobel@example.com\",
\"password\": \"password\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/auth/login"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"email": "lrobel@example.com",
"password": "password"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"token": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Me
requires authentication No specific permission required
Get the current user
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/auth/user" \
--header "Authorization: Bearer 6caEDP41ekZba3V5v8h6gdf" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/auth/user"
);
const headers = {
"Authorization": "Bearer 6caEDP41ekZba3V5v8h6gdf",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "d8e9bb93-5ef3-3e2c-b638-78ad5578173b",
"name": "Ms. Eva Roob",
"username": "brakus.antoinette",
"email": "ritchie.celia@example.com",
"ability": [
{
"action": "read",
"subject": "Auth"
},
{
"action": "listar",
"subject": "padrão"
}
],
"roles": [],
"preferences": [],
"sectors": [],
"image": {
"id": null,
"url": null
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update Profile
requires authentication No specific permission required
Update the current user profile
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/auth/user" \
--header "Authorization: Bearer Z5D8E4kv3V1adcbh6fPa6ge" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"certification\": \"Example Certification\",
\"crea\": \"Example Crea\",
\"email\": \"user@example.com\",
\"username\": \"erich.gutmann\",
\"password\": \"password123\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"name\": \"Example Name\",
\"extension\": \"Example Image extension\",
\"size\": \"Example Image size\"
},
\"sectors\": [
\"8e027afb-532a-3b6d-b016-158804122bc5\"
],
\"roles\": [
\"449a933c-d386-316b-ac2a-71299e8f9357\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/auth/user"
);
const headers = {
"Authorization": "Bearer Z5D8E4kv3V1adcbh6fPa6ge",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"certification": "Example Certification",
"crea": "Example Crea",
"email": "user@example.com",
"username": "erich.gutmann",
"password": "password123",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"name": "Example Name",
"extension": "Example Image extension",
"size": "Example Image size"
},
"sectors": [
"8e027afb-532a-3b6d-b016-158804122bc5"
],
"roles": [
"449a933c-d386-316b-ac2a-71299e8f9357"
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Logout
requires authentication No specific permission required
Logout the current user
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/auth/logout" \
--header "Authorization: Bearer Z6vk4afVPabh51cDE8g3e6d" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/auth/logout"
);
const headers = {
"Authorization": "Bearer Z6vk4afVPabh51cDE8g3e6d",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get user preferences
requires authentication No specific permission required
Get all user preferences
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/auth/preferences" \
--header "Authorization: Bearer g85h1a3EbDvVPkaf4ceZ6d6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/auth/preferences"
);
const headers = {
"Authorization": "Bearer g85h1a3EbDvVPkaf4ceZ6d6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"theme": "dark",
"language": "pt-br",
"notifications": {
"email": true,
"sms": false
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Set user preference
requires authentication No specific permission required
Set or update a user preference
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/auth/preferences" \
--header "Authorization: Bearer 6k5c4v8VDagbeZfa13dhP6E" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"key\": \"llcauucbedyxd\",
\"value\": []
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/auth/preferences"
);
const headers = {
"Authorization": "Bearer 6k5c4v8VDagbeZfa13dhP6E",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"key": "llcauucbedyxd",
"value": []
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Preference saved successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete user preference
requires authentication No specific permission required
Delete a specific user preference
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/auth/preferences/commodi" \
--header "Authorization: Bearer k8DEe1aa664VPhcZ5dvfg3b" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/auth/preferences/commodi"
);
const headers = {
"Authorization": "Bearer k8DEe1aa664VPhcZ5dvfg3b",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "Preference deleted successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate user token
requires authentication auth generate-token
Generate a token for a specific user
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/auth/550e8400-e29b-41d4-a716-446655440000/token" \
--header "Authorization: Bearer e3kP1vg8hfDbaE6a64ZV5cd" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/auth/550e8400-e29b-41d4-a716-446655440000/token"
);
const headers = {
"Authorization": "Bearer e3kP1vg8hfDbaE6a64ZV5cd",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"token": "string",
"userData": {
"id": "uuid",
"name": "string",
"username": "string",
"email": "string",
"ability": [
"array"
],
"roles": [
"array"
],
"preferences": [
"array"
],
"sectors": [
"array"
],
"image": {
"id": "uuid",
"url": "string"
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Bank Account Movements
Endpoints for bank account deposits, withdraws and transfers
Transfer between bank accounts
requires authentication bank-account transfer
Transfers funds from a source account to a destination account
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/transfers" \
--header "Authorization: Bearer fadE68e36ckvghPZ1DaVb45" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"source_id\": \"Example Source id\",
\"destination_id\": \"Example Destination id\",
\"amount\": 1,
\"description\": \"Example Description\",
\"transaction_date\": \"2024-01-01\",
\"transaction_category_id\": \"Example Transaction category id\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/transfers"
);
const headers = {
"Authorization": "Bearer fadE68e36ckvghPZ1DaVb45",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"source_id": "Example Source id",
"destination_id": "Example Destination id",
"amount": 1,
"description": "Example Description",
"transaction_date": "2024-01-01",
"transaction_category_id": "Example Transaction category id"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string",
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete a bank transfer
requires authentication bank-account transfer
Reverts a transfer by deleting both cash flows and the transfer record
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/transfers/ipsum" \
--header "Authorization: Bearer 81b53fhDa4dVkvg6aPe6ZcE" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/transfers/ipsum"
);
const headers = {
"Authorization": "Bearer 81b53fhDa4dVkvg6aPe6ZcE",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Deposit into bank account
requires authentication bank-account deposit
Adds funds to a bank account
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/3/deposit" \
--header "Authorization: Bearer bV3vaaPZ6f8g14DEe6hcd5k" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"amount\": 1,
\"description\": \"Example Description\",
\"transaction_date\": \"2024-01-01\",
\"transaction_category_id\": \"Example Transaction category id\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/3/deposit"
);
const headers = {
"Authorization": "Bearer bV3vaaPZ6f8g14DEe6hcd5k",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"amount": 1,
"description": "Example Description",
"transaction_date": "2024-01-01",
"transaction_category_id": "Example Transaction category id"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Withdraw from bank account
requires authentication bank-account withdraw
Removes funds from a bank account
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/10/withdraw" \
--header "Authorization: Bearer hkf15aP48eadZcgb6D3vV6E" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"amount\": 1,
\"description\": \"Example Description\",
\"transaction_date\": \"2024-01-01\",
\"transaction_category_id\": \"Example Transaction category id\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/10/withdraw"
);
const headers = {
"Authorization": "Bearer hkf15aP48eadZcgb6D3vV6E",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"amount": 1,
"description": "Example Description",
"transaction_date": "2024-01-01",
"transaction_category_id": "Example Transaction category id"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Bank Accounts
Endpoints for bank accounts
Get bank account balance summary
requires authentication bank-account summary
Get the balance summary of all bank accounts
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/bank-accounts/balance-summary" \
--header "Authorization: Bearer 5DhbEd3Vka1ge466ZfPvca8" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/balance-summary"
);
const headers = {
"Authorization": "Bearer 5DhbEd3Vka1ge466ZfPvca8",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"totalBalance": "number",
"totalBalancePositive": "number",
"totalBalanceNegative": "number",
"totalLimit": "number",
"totalAvailableBalance": "number",
"totalUsedLimit": "number",
"totalAvailableLimit": "number",
"accounts": {
"*": {
"id": "string",
"bank": "string",
"balance": "number",
"limit": "number",
"available_balance": "number",
"used_limit": "number",
"available_limit": "number"
}
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get default bank account by payment method
requires authentication bank-account show
Returns the bank account configured as default for the given payment method. Responds 404 when no default is configured.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/bank-accounts/default-by-payment-method?method=cash" \
--header "Authorization: Bearer caf4VEg531DkdebPv6Zha86" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/default-by-payment-method"
);
const params = {
"method": "cash",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer caf4VEg531DkdebPv6Zha86",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "796a4757-fb5c-36e3-a62f-cd5efba92fb0",
"agency": "7174",
"account": "3044989-3",
"type": "caixa",
"balance": 6497.58,
"holder_type": "pj",
"alias": "ullam",
"limit": 2850.73,
"available_balance": 9348.31,
"used_limit": 0,
"available_limit": 2850.73,
"is_default": null,
"default_payment_method": null,
"bank": {
"id": null,
"name": null,
"code": null
},
"created_at": null,
"updated_at": null
}
}
Example response (404):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List bank accounts
requires authentication bank-account index
List all bank accounts
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/bank-accounts?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=name&is_default=1" \
--header "Authorization: Bearer DfgcahZd63b4ae5kvPVE168" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "name",
"is_default": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer DfgcahZd63b4ae5kvPVE168",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "0e9f5176-bafb-3608-968c-99bfde98c177",
"agency": "2956",
"account": "2673094-9",
"type": "poupança",
"balance": 3667.9,
"holder_type": "pj",
"alias": "possimus",
"limit": 6400.98,
"available_balance": 10068.88,
"used_limit": 0,
"available_limit": 6400.98,
"is_default": null,
"default_payment_method": null,
"bank": {
"id": null,
"name": null,
"code": null
},
"created_at": null,
"updated_at": null
},
{
"id": "178a9d83-41d9-39c3-bdb4-3ff3ae37ff5e",
"agency": "3650",
"account": "5302055-3",
"type": "caixa",
"balance": 1155.05,
"holder_type": "pj",
"alias": "voluptatem",
"limit": 3169.2,
"available_balance": 4324.25,
"used_limit": 0,
"available_limit": 3169.2,
"is_default": null,
"default_payment_method": null,
"bank": {
"id": null,
"name": null,
"code": null
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create bank account
requires authentication bank-account store
Create a new bank account
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/bank-accounts" \
--header "Authorization: Bearer fagakV6Z54h1Pc3bE86Dedv" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"agency\": \"Example Agency\",
\"account\": \"4022027-9\",
\"bank_id\": \"4da98cb5-2b4a-34ec-9a46-9ba012e95155\",
\"type\": \"Example Type\",
\"holder_type\": \"Example Holder type\",
\"alias\": \"Example Alias\",
\"balance\": 1,
\"limit\": 1,
\"is_default\": true,
\"default_payment_method\": \"Example Default payment method\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts"
);
const headers = {
"Authorization": "Bearer fagakV6Z54h1Pc3bE86Dedv",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"agency": "Example Agency",
"account": "4022027-9",
"bank_id": "4da98cb5-2b4a-34ec-9a46-9ba012e95155",
"type": "Example Type",
"holder_type": "Example Holder type",
"alias": "Example Alias",
"balance": 1,
"limit": 1,
"is_default": true,
"default_payment_method": "Example Default payment method"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update bank account
requires authentication bank-account update
Update a bank account
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/15" \
--header "Authorization: Bearer 6Vc1P3gk5ab6vheaZ8EfD4d" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"agency\": \"Example Agency\",
\"account\": \"7100832-7\",
\"bank_id\": \"61b0e8e1-79ac-3835-a555-c1bf8ce54b69\",
\"type\": \"Example Type\",
\"holder_type\": \"Example Holder type\",
\"alias\": \"Example Alias\",
\"balance\": 1,
\"limit\": 1,
\"is_default\": true,
\"default_payment_method\": \"Example Default payment method\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/15"
);
const headers = {
"Authorization": "Bearer 6Vc1P3gk5ab6vheaZ8EfD4d",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"agency": "Example Agency",
"account": "7100832-7",
"bank_id": "61b0e8e1-79ac-3835-a555-c1bf8ce54b69",
"type": "Example Type",
"holder_type": "Example Holder type",
"alias": "Example Alias",
"balance": 1,
"limit": 1,
"is_default": true,
"default_payment_method": "Example Default payment method"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show bank account
requires authentication bank-account show
Show a bank account
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/bank-accounts/20" \
--header "Authorization: Bearer Dva6hbgaE8513cfe4ZPkVd6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/20"
);
const headers = {
"Authorization": "Bearer Dva6hbgaE8513cfe4ZPkVd6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "73c895cc-3e50-37d5-87bd-3759e579ef7e",
"agency": "7483",
"account": "4887393-3",
"type": "corrente",
"balance": 9782.75,
"holder_type": "pf",
"alias": "iusto",
"limit": 8078.61,
"available_balance": 17861.36,
"used_limit": 0,
"available_limit": 8078.61,
"is_default": null,
"default_payment_method": null,
"bank": {
"id": null,
"name": null,
"code": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete bank account
requires authentication bank-account delete
Delete a bank account
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/4" \
--header "Authorization: Bearer 38dDv15kbVgecaZaP6f6Eh4" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/4"
);
const headers = {
"Authorization": "Bearer 38dDv15kbVgecaZaP6f6Eh4",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Bank Statements
Endpoints for bank account statements (extrato bancário)
Bank statement summary
requires authentication bank-statement summary
Get aggregated summary for the period
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/bank-accounts/9/statements/summary" \
--header "Authorization: Bearer ak6bcfg4aev8EZdhP56DV31" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"date_start\": \"2024-01-01\",
\"date_end\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/9/statements/summary"
);
const headers = {
"Authorization": "Bearer ak6bcfg4aev8EZdhP56DV31",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"date_start": "2024-01-01",
"date_end": "2024-01-01"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"opening_balance": "number",
"closing_balance": "number",
"total_credit": "number",
"total_debit": "number",
"count": "integer",
"date_start": "string",
"date_end": "string"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List bank statements
requires authentication bank-statement index
List statements for a bank account. Default period: last 30 days.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/bank-accounts/19/statements" \
--header "Authorization: Bearer ehakbEaf6gVZPD5d8c1v634" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"sort_by\": \"magnam\",
\"sort_desc\": true,
\"page\": 42,
\"per_page\": 17,
\"q\": \"bibjlvailazvcwnqvtovtetqk\",
\"type\": \"juros\",
\"date_start\": \"2026-11-26T13:17:37\",
\"date_end\": \"2072-07-27\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/19/statements"
);
const headers = {
"Authorization": "Bearer ehakbEaf6gVZPD5d8c1v634",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"sort_by": "magnam",
"sort_desc": true,
"page": 42,
"per_page": 17,
"q": "bibjlvailazvcwnqvtovtetqk",
"type": "juros",
"date_start": "2026-11-26T13:17:37",
"date_end": "2072-07-27"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": null,
"type": null,
"amount": null,
"balance_after": null,
"description": null,
"date": null,
"statement_date": null,
"created_at": null,
"updated_at": null
},
{
"id": null,
"type": null,
"amount": null,
"balance_after": null,
"description": null,
"date": null,
"statement_date": null,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show bank statement
requires authentication bank-statement show
Show a specific statement entry
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/bank-accounts/5/statements/voluptate" \
--header "Authorization: Bearer 3ha6f8kcg51ebdV4EZPDa6v" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/bank-accounts/5/statements/voluptate"
);
const headers = {
"Authorization": "Bearer 3ha6f8kcg51ebdV4EZPDa6v",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": null,
"type": null,
"amount": null,
"balance_after": null,
"description": null,
"date": null,
"statement_date": null,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Banks
Endpoints for banks
List banks
requires authentication bank index
List all banks
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/banks?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Permission+name" \
--header "Authorization: Bearer 41dh5afbE8Pe6ag3vDZ6Vck" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/banks"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Permission name",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 41dh5afbE8Pe6ag3vDZ6Vck",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "0074aad2-9dea-3503-829e-4b2f93e30e5c",
"name": "Lutero Comercial Ltda.",
"code": "721"
},
{
"id": "f34ca82c-e1f1-3dee-a6f1-fcf96417bbce",
"name": "Oliveira e Queirós",
"code": "623"
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create bank
requires authentication bank store
Create a new bank
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/banks" \
--header "Authorization: Bearer g8ab6Dhfvecdk5Z4E61V3aP" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"code\": \"Example Code\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/banks"
);
const headers = {
"Authorization": "Bearer g8ab6Dhfvecdk5Z4E61V3aP",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"code": "Example Code"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update bank
requires authentication bank update
Update a bank
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/banks/1" \
--header "Authorization: Bearer 3k6vDeabVZfcP5h1da684Eg" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"code\": \"Example Code\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/banks/1"
);
const headers = {
"Authorization": "Bearer 3k6vDeabVZfcP5h1da684Eg",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"code": "Example Code"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show bank
requires authentication bank show
Show a bank
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/banks/1" \
--header "Authorization: Bearer k8e3bfgd5h4Z6ac16vVDaEP" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/banks/1"
);
const headers = {
"Authorization": "Bearer k8e3bfgd5h4Z6ac16vVDaEP",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "0c4dc09a-4562-383b-ad38-6e6915740bdb",
"name": "Brito Comercial Ltda.",
"code": "45"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete bank
requires authentication bank delete
Delete a bank
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/banks/1" \
--header "Authorization: Bearer 8gava6D4febkEPcVZ1dh536" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/banks/1"
);
const headers = {
"Authorization": "Bearer 8gava6D4febkEPcVZ1dh536",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
CEP
Search CEP
requires authentication No specific permission required
Search for address information by CEP (Brazilian postal code)
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cep/01001000" \
--header "Authorization: Bearer 6ca134EagZfkh6P8DV5vdbe" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cep/01001000"
);
const headers = {
"Authorization": "Bearer 6ca134EagZfkh6P8DV5vdbe",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200, CEP found successfully):
{
"data": {
"cep": "01001000",
"street": "Praça da Sé",
"district": "Sé",
"city": "São Paulo",
"state": "SP",
"complement": "lado ímpar",
"ibge": "3550308",
"ddd": "11",
"siafi": "7107"
}
}
Example response (200, CEP not found):
{
"data": {
"cep": "99999999",
"street": null,
"district": null,
"city": null,
"state": null,
"complement": null,
"ibge": null,
"ddd": null,
"siafi": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cash Flow
Endpoints for cash flow
Get cash flow summary
requires authentication cash-flow summary
Get cash flow summary
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cash-flows/summary?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Salary&cash_session=uuid&type=entrada&description=Ut+non+est+sapiente.&categories[]=in&date_start=2021-01-01&date_end=2021-01-31&bank_accounts[]=omnis&customers[]=autem&suppliers[]=rerum&works[]=voluptates&cost_centers[]=deleniti" \
--header "Authorization: Bearer e6b58PdVDZfE6hv1a3kcga4" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-flows/summary"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Salary",
"cash_session": "uuid",
"type": "entrada",
"description": "Ut non est sapiente.",
"categories[0]": "in",
"date_start": "2021-01-01",
"date_end": "2021-01-31",
"bank_accounts[0]": "omnis",
"customers[0]": "autem",
"suppliers[0]": "rerum",
"works[0]": "voluptates",
"cost_centers[0]": "deleniti",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer e6b58PdVDZfE6hv1a3kcga4",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"total_income": "number",
"total_expense": "number",
"total_fee": "number",
"total_balance": "number"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List cash flow
requires authentication cash-flow index
List all cash flow
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cash-flows?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Salary&cash_session=uuid&type=entrada&description=Eligendi+dolores+ea+quod+nihil.&categories[]=quam&date_start=2021-01-01&date_end=2021-01-31&bank_accounts[]=impedit&customers[]=fuga&suppliers[]=maxime&works[]=dolor&cost_centers[]=voluptatem" \
--header "Authorization: Bearer k65P1avh3Z8EDa6gVdcf4eb" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-flows"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Salary",
"cash_session": "uuid",
"type": "entrada",
"description": "Eligendi dolores ea quod nihil.",
"categories[0]": "quam",
"date_start": "2021-01-01",
"date_end": "2021-01-31",
"bank_accounts[0]": "impedit",
"customers[0]": "fuga",
"suppliers[0]": "maxime",
"works[0]": "dolor",
"cost_centers[0]": "voluptatem",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer k65P1avh3Z8EDa6gVdcf4eb",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "0b45d100-e7d9-39e7-90c7-2a8911bfbd8c",
"code": "FC-50980495",
"type": "tarifa",
"amount": -5906.39,
"description": "Ipsa hic enim soluta hic aliquid velit.",
"transaction_date": "2024-08-25T03:00:00.000000Z",
"transaction_category": {
"id": null,
"name": null,
"type": null
},
"created_at": null,
"updated_at": null
},
{
"id": "aa980980-4984-3286-933c-07f1fa3ba0e4",
"code": "FC-35530538",
"type": "transferência",
"amount": -2631.76,
"description": "Temporibus qui eveniet a laboriosam itaque laboriosam consequatur.",
"transaction_date": "2009-03-14T03:00:00.000000Z",
"transaction_category": {
"id": null,
"name": null,
"type": null
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create cash flow
requires authentication cash-flow store
Create a new cash flow
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/cash-flows" \
--header "Authorization: Bearer vadV63ce6Z5Pbkfa1Dh4g8E" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"type\": \"Example Type\",
\"cash_session_id\": \"e790e888-deb3-3b87-a06b-2c3bf8cb396f\",
\"transaction_category_id\": \"3cc4cfa1-3010-3692-b9f8-3da56ad83682\",
\"bank_account_id\": \"fda218c3-414a-3ef3-8c11-1ddb22ddfb0c\",
\"customer_id\": \"c2ac4f8e-7272-3827-9a94-646c594aa00b\",
\"supplier_id\": \"23f0f9bb-2526-304f-86b3-38219426e4de\",
\"work_id\": \"c68943c9-f29b-3f90-8afb-c54d1d729866\",
\"cost_center_id\": \"3a1203cc-e9de-3e0b-8fab-e6ceedf566f5\",
\"amount\": 1,
\"description\": \"Example Description\",
\"transaction_date\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-flows"
);
const headers = {
"Authorization": "Bearer vadV63ce6Z5Pbkfa1Dh4g8E",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"type": "Example Type",
"cash_session_id": "e790e888-deb3-3b87-a06b-2c3bf8cb396f",
"transaction_category_id": "3cc4cfa1-3010-3692-b9f8-3da56ad83682",
"bank_account_id": "fda218c3-414a-3ef3-8c11-1ddb22ddfb0c",
"customer_id": "c2ac4f8e-7272-3827-9a94-646c594aa00b",
"supplier_id": "23f0f9bb-2526-304f-86b3-38219426e4de",
"work_id": "c68943c9-f29b-3f90-8afb-c54d1d729866",
"cost_center_id": "3a1203cc-e9de-3e0b-8fab-e6ceedf566f5",
"amount": 1,
"description": "Example Description",
"transaction_date": "2024-01-01"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show cash flow
requires authentication cash-flow show
Show a cash flow
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cash-flows/5" \
--header "Authorization: Bearer EvfakZ3c5db6ea6PV4Dh8g1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-flows/5"
);
const headers = {
"Authorization": "Bearer EvfakZ3c5db6ea6PV4Dh8g1",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "06d49504-891c-3ca5-b485-bf41cc5a8f32",
"code": "FC-04809156",
"type": "depósito",
"amount": 9372.79,
"description": "Soluta ea sed quibusdam.",
"transaction_date": "2024-08-24T03:00:00.000000Z",
"transaction_category": {
"id": null,
"name": null,
"type": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update cash flow
requires authentication cash-flow update
Update a cash flow
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/cash-flows/11" \
--header "Authorization: Bearer 5fbPvZd3e8g1akEhD664acV" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"type\": \"Example Type\",
\"cash_session_id\": \"eb367656-53f7-36a3-a86f-2bbcd85f1c9f\",
\"transaction_category_id\": \"6201ad79-903e-380f-b5fc-51768065c00f\",
\"bank_account_id\": \"718ca803-98bc-3a62-921a-c289486176bc\",
\"customer_id\": \"69090137-a983-3dcf-8ab8-9bdc520dc7ca\",
\"supplier_id\": \"1b2624d3-e597-3257-80d4-ffd77fc8b33f\",
\"work_id\": \"8e5a44d9-a6f9-3de0-9d2f-e1661bb6217b\",
\"cost_center_id\": \"34dac30a-d8a2-3c86-8b08-99ab7d863ec6\",
\"amount\": 1,
\"description\": \"Example Description\",
\"transaction_date\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-flows/11"
);
const headers = {
"Authorization": "Bearer 5fbPvZd3e8g1akEhD664acV",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"type": "Example Type",
"cash_session_id": "eb367656-53f7-36a3-a86f-2bbcd85f1c9f",
"transaction_category_id": "6201ad79-903e-380f-b5fc-51768065c00f",
"bank_account_id": "718ca803-98bc-3a62-921a-c289486176bc",
"customer_id": "69090137-a983-3dcf-8ab8-9bdc520dc7ca",
"supplier_id": "1b2624d3-e597-3257-80d4-ffd77fc8b33f",
"work_id": "8e5a44d9-a6f9-3de0-9d2f-e1661bb6217b",
"cost_center_id": "34dac30a-d8a2-3c86-8b08-99ab7d863ec6",
"amount": 1,
"description": "Example Description",
"transaction_date": "2024-01-01"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete cash flow
requires authentication cash-flow delete
Delete a cash flow
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/cash-flows/3" \
--header "Authorization: Bearer 6Eb6kPe8h3Z1avfDd4cag5V" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-flows/3"
);
const headers = {
"Authorization": "Bearer 6Eb6kPe8h3Z1avfDd4cag5V",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cash Session
Endpoints for cash session
List cash session
requires authentication cash-session index
List all cash session
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cash-sessions" \
--header "Authorization: Bearer ak458ce6gVhf36baEZDdv1P" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-sessions"
);
const headers = {
"Authorization": "Bearer ak458ce6gVhf36baEZDdv1P",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "463648e1-d435-339a-a2ab-bae43944429f",
"code": null,
"opened_by": null,
"opened_at": "1979-09-02T15:58:10.000000Z",
"closed_by": null,
"closed_at": "2000-06-29T04:35:27.000000Z",
"opening_balance": 2553.88,
"closing_balance": 2584.05,
"total_income": 0,
"total_expense": 0,
"total_balance": 0,
"status": "Aberto",
"hasSnapshot": false,
"created_at": "1979-12-28T05:34:35.000000Z",
"updated_at": "1998-08-04T07:15:08.000000Z"
},
{
"id": "b2c5633b-bb4d-3e44-a59a-a0ffffe706c8",
"code": null,
"opened_by": null,
"opened_at": "2009-04-03T15:36:23.000000Z",
"closed_by": null,
"closed_at": "2008-04-29T22:37:39.000000Z",
"opening_balance": 2377.09,
"closing_balance": 331.82,
"total_income": 0,
"total_expense": 0,
"total_balance": 0,
"status": "Aberto",
"hasSnapshot": false,
"created_at": "1971-12-05T20:12:10.000000Z",
"updated_at": "2011-02-16T04:26:30.000000Z"
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Open cash session
requires authentication cash-session open
Open a new cash session
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/cash-sessions/open" \
--header "Authorization: Bearer feDVbc6aP4ZvEd681hk3g5a" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-sessions/open"
);
const headers = {
"Authorization": "Bearer feDVbc6aP4ZvEd681hk3g5a",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "020ae477-be4e-3dd4-a209-289ab3b81d9e",
"code": null,
"opened_by": null,
"opened_at": "2007-02-12T18:35:19.000000Z",
"closed_by": null,
"closed_at": "1994-06-19T07:12:44.000000Z",
"opening_balance": 2289.12,
"closing_balance": 6606.6,
"total_income": 0,
"total_expense": 0,
"total_balance": 0,
"status": "Aberto",
"hasSnapshot": false,
"created_at": "2013-08-02T00:08:29.000000Z",
"updated_at": "1976-12-16T05:02:53.000000Z"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Close cash session
requires authentication cash-session close
Close a cash session
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/cash-sessions/close/929ba7c0-f483-3447-8828-a2620448b418" \
--header "Authorization: Bearer 8Dkda31gvEb6Ve5cZ4fa6hP" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-sessions/close/929ba7c0-f483-3447-8828-a2620448b418"
);
const headers = {
"Authorization": "Bearer 8Dkda31gvEb6Ve5cZ4fa6hP",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cash session account snapshot
requires authentication cash-session show
List the account balance snapshot captured when the cash session was closed
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cash-sessions/12ec29eb-dd69-3786-ab49-680f575e62c3/account-snapshot" \
--header "Authorization: Bearer g86ckv5VaaE6beD4Pdh3f1Z" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-sessions/12ec29eb-dd69-3786-ab49-680f575e62c3/account-snapshot"
);
const headers = {
"Authorization": "Bearer g86ckv5VaaE6beD4Pdh3f1Z",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show cash session
requires authentication cash-session show
Show a cash session
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cash-sessions/9d39c1f9-2c67-346e-a715-6f5ba2e4c4cf" \
--header "Authorization: Bearer aE86fDZPkvdgb461e3haVc5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-sessions/9d39c1f9-2c67-346e-a715-6f5ba2e4c4cf"
);
const headers = {
"Authorization": "Bearer aE86fDZPkvdgb461e3haVc5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "39a906ba-0211-3341-810a-a597a89bbd66",
"code": null,
"opened_by": null,
"opened_at": "1998-08-13T20:28:08.000000Z",
"closed_by": null,
"closed_at": "2025-05-23T11:35:28.000000Z",
"opening_balance": 3344.41,
"closing_balance": 3839.97,
"total_income": 0,
"total_expense": 0,
"total_balance": 0,
"status": "Aberto",
"hasSnapshot": false,
"created_at": "2024-04-11T22:16:51.000000Z",
"updated_at": "1972-10-29T18:33:38.000000Z"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete cash session
requires authentication cash-session delete
Delete a cash session
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/cash-sessions/4c116b01-bc58-3c18-bc48-6d0fc40cfd24" \
--header "Authorization: Bearer 6h6PgavcZkbEf1V3d8aD45e" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cash-sessions/4c116b01-bc58-3c18-bc48-6d0fc40cfd24"
);
const headers = {
"Authorization": "Bearer 6h6PgavcZkbEf1V3d8aD45e",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Central de Tutoriais
Consulta dos tutoriais liberados para quem está autenticado
Setores da central
requires authentication No specific permission required
Setores da pessoa que tenham ao menos um tutorial visível, com a contagem
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/tutorials/sectors" \
--header "Authorization: Bearer 8fea6bD5kaPghVc136E4vZd" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/tutorials/sectors"
);
const headers = {
"Authorization": "Bearer 8fea6bD5kaPghVc136E4vZd",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "c9fc8022-1b67-36e5-9e71-f0323cea2dc8",
"name": "modi et",
"slug": null,
"abbreviation": null,
"tutorials_count": 0
},
{
"id": "133d28ab-c8c7-333f-a1c5-0a3db64a7fdf",
"name": "qui autem",
"slug": null,
"abbreviation": null,
"tutorials_count": 0
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Módulos da central
requires authentication No specific permission required
Módulos ativos com tutoriais visíveis para a pessoa; aceita filtro de setor
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/tutorials/modules" \
--header "Authorization: Bearer eb48a6ZdkvcPE65hDf3ag1V" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/tutorials/modules"
);
const headers = {
"Authorization": "Bearer eb48a6ZdkvcPE65hDf3ag1V",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "1e561070-7600-3c55-a7fc-66f97e260209",
"name": "Doloremque quam",
"slug": "doloremque-quam-346833",
"description": "Beatae quasi pariatur eaque maxime beatae necessitatibus perferendis.",
"icon": null,
"color": null,
"sort_order": 0,
"is_active": true,
"created_at": null,
"updated_at": null
},
{
"id": "adcf5fb3-1f89-3dda-b06d-160d7b571eaa",
"name": "Dolor doloremque",
"slug": "dolor-doloremque-502367",
"description": "Deserunt dolor est quo facilis velit.",
"icon": null,
"color": null,
"sort_order": 0,
"is_active": true,
"created_at": null,
"updated_at": null
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Listar tutoriais
requires authentication No specific permission required
Lista paginada dos tutoriais visíveis, com filtros de módulo, setor e busca por texto
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/tutorials?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=ordem+de+servi%C3%A7o&module_id[]=1d01f108-b466-3343-acff-d28ae1f0bce9" \
--header "Authorization: Bearer VP1Ehk63568faabg4DdvceZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/tutorials"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "ordem de serviço",
"module_id[0]": "1d01f108-b466-3343-acff-d28ae1f0bce9",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer VP1Ehk63568faabg4DdvceZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "b651cc64-0808-38e3-a144-4c71661e7d4d",
"title": "Illum delectus nulla aliquam",
"description": "Ut porro quia tempore aut vel nam aut voluptas.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-84ad-44c4-a735-591b961c7bae",
"name": "Natus consequatur",
"slug": "natus-consequatur-415978",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
},
{
"id": "0cfac550-ab0f-3760-b9ba-584c7e52ecd0",
"title": "Ipsum quaerat eos quod",
"description": "Minima ut laudantium a id perspiciatis.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-8da8-4dbf-b6d3-02b01498eb00",
"name": "Enim est",
"slug": "enim-est-778806",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Detalhe do tutorial
requires authentication No specific permission required
Tutorial com os itens em ordem. Fora da visibilidade, responde 404.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/tutorials/1" \
--header "Authorization: Bearer kaVegd6f438vZDE5a1hcbP6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/tutorials/1"
);
const headers = {
"Authorization": "Bearer kaVegd6f438vZDE5a1hcbP6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "46e38829-1f1b-33f4-8c7f-78b77ea0314d",
"title": "Ut quia est ut",
"description": "Ea qui vero accusantium minus ratione quis sapiente.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-9378-4285-b0c8-b162d4d12e8b",
"name": "Excepturi et",
"slug": "excepturi-et-228584",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
URL do item
requires authentication No specific permission required
Devolve a URL assinada de curta validade para o arquivo no S3, ou o link externo do item. O caminho bruto do S3 nunca é exposto.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/tutorial-items/019556e7-2e9f-777c-a177-30bbf0646c32/url" \
--header "Authorization: Bearer ZagavbV6h5fEP41Dc386dek" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/tutorial-items/019556e7-2e9f-777c-a177-30bbf0646c32/url"
);
const headers = {
"Authorization": "Bearer ZagavbV6h5fEP41Dc386dek",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"type": "string",
"title": "string",
"url": "string",
"expires_in": "integer",
"mime_type": "string",
"size_bytes": "integer"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Contracts
Endpoints for managing work contracts
List contracts
requires authentication contract index
List all work contracts
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/contracts" \
--header "Authorization: Bearer ve4a38f1VghPdE56bDa6Zkc" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"sort_by\": \"Example Sort by\",
\"sort_desc\": true,
\"page\": 1,
\"per_page\": 1,
\"work_id\": \"08e148cb-a780-36d1-8d39-33afcc6a44e1\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/contracts"
);
const headers = {
"Authorization": "Bearer ve4a38f1VghPdE56bDa6Zkc",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"sort_by": "Example Sort by",
"sort_desc": true,
"page": 1,
"per_page": 1,
"work_id": "08e148cb-a780-36d1-8d39-33afcc6a44e1"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "e5104536-b802-35c3-b954-b97e847baf9a",
"number": "396/2026",
"started_at": "2026-11-26",
"deadline_at": "2027-11-26",
"work": {
"id": "a351a0d1-1db2-497c-ad5e-2753fb8f20d5",
"name": "Lívia Constância Pontes Jr."
},
"created_at": null,
"updated_at": null
},
{
"id": "b3597c27-493a-352b-9590-10a1ca52e1eb",
"number": "712/2026",
"started_at": "2026-11-26",
"deadline_at": "2027-11-26",
"work": {
"id": "a351a0d1-2ad8-42f4-a1bc-5133e7cd65e3",
"name": "Mariah Ortiz Verdugo Jr."
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create contract
requires authentication contract store
Create a new contract for a work
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/contracts" \
--header "Authorization: Bearer 1ch6Zeg8Va3dkDf5bv4aEP6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"work_id\": \"1005422f-9e8b-3b22-a668-1c2b2aa830e3\",
\"number\": \"Example Number\",
\"started_at\": \"Example Started at\",
\"deadline_at\": \"Example Deadline at\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/contracts"
);
const headers = {
"Authorization": "Bearer 1ch6Zeg8Va3dkDf5bv4aEP6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"work_id": "1005422f-9e8b-3b22-a668-1c2b2aa830e3",
"number": "Example Number",
"started_at": "Example Started at",
"deadline_at": "Example Deadline at"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show contract
requires authentication contract show
Show a work contract
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/contracts/8" \
--header "Authorization: Bearer g1f6dakhD8aE34bVc65PvZe" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/contracts/8"
);
const headers = {
"Authorization": "Bearer g1f6dakhD8aE34bVc65PvZe",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "7dbe559a-127f-34cb-9c3b-2d6c0818ffc9",
"number": "237/2026",
"started_at": "2026-11-26",
"deadline_at": "2027-11-26",
"work": {
"id": "a351a0d1-3804-4ae5-9997-05c3bcf74066",
"name": "Tainara Ramos"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update contract
requires authentication contract update
Update a work contract
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/contracts/17" \
--header "Authorization: Bearer 6Zafd5hPVvak4b31g6Ec8eD" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"number\": \"Example Number\",
\"started_at\": \"Example Started at\",
\"deadline_at\": \"Example Deadline at\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/contracts/17"
);
const headers = {
"Authorization": "Bearer 6Zafd5hPVvak4b31g6Ec8eD",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"number": "Example Number",
"started_at": "Example Started at",
"deadline_at": "Example Deadline at"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete contract
requires authentication contract delete
Delete a work contract
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/contracts/ducimus" \
--header "Authorization: Bearer dvDgkae6Pa5f348bVZ16hcE" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/contracts/ducimus"
);
const headers = {
"Authorization": "Bearer dvDgkae6Pa5f348bVZ16hcE",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cost Centers
Endpoints for cost centers
Suggest next code
requires authentication cost-center index
Próximo código livre sob o pai informado. O código é sugestão e pode ser alterado antes de salvar.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cost-centers/next-code?parent_id=quam" \
--header "Authorization: Bearer 5h4dvZPVbagE8akcf13D66e" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"parent_id\": \"dolore\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers/next-code"
);
const params = {
"parent_id": "quam",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 5h4dvZPVbagE8akcf13D66e",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"parent_id": "dolore"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"code": "001.002"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cost center requirement
requires authentication cost-center requirement-config index
Data a partir da qual o centro de custo é obrigatório em lançamentos novos. A tela usa isso para marcar o campo como obrigatório sem precisar tentar salvar.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cost-centers/requirement-config" \
--header "Authorization: Bearer 1feaDb46Z8h6Egk5dP3Vcav" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers/requirement-config"
);
const headers = {
"Authorization": "Bearer 1feaDb46Z8h6Egk5dP3Vcav",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"required_from": "2026-11-03",
"required_now": true
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update cost center requirement
requires authentication cost-center requirement-config update
Ajusta a data de corte. Enviar nulo desliga a obrigatoriedade.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/cost-centers/requirement-config" \
--header "Authorization: Bearer 5h4akEdga1f6v3ebcD8ZV6P" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"required_from\": \"2026-11-03\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers/requirement-config"
);
const headers = {
"Authorization": "Bearer 5h4akEdga1f6v3ebcD8ZV6P",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"required_from": "2026-11-03"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"required_from": "2026-11-03",
"required_now": true
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Stock cost center
requires authentication cost-center stock-config index
Centro de custo que recebe a compra de material. A conta a pagar gerada por NF-e de produto nasce nele, porque o custo do material chega à obra pela movimentação de estoque.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cost-centers/stock-config" \
--header "Authorization: Bearer 5aEZ38cgvdbfD4heP661Vka" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers/stock-config"
);
const headers = {
"Authorization": "Bearer 5aEZ38cgvdbfD4heP661Vka",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"cost_center": {
"id": "uuid",
"code": "003.001",
"name": "Estoque central"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update stock cost center
requires authentication cost-center stock-config update
Aponta a configuração para outro centro. Nulo desliga: a conta da nota passa a nascer sem centro, para ser classificada na conferência.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/cost-centers/stock-config" \
--header "Authorization: Bearer 41v5VPfEkha6e3cbdZ8g6aD" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"cost_center_id\": \"qui\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers/stock-config"
);
const headers = {
"Authorization": "Bearer 41v5VPfEkha6e3cbdZ8g6aD",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"cost_center_id": "qui"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"cost_center": {
"id": "uuid",
"code": "003.001",
"name": "Estoque central"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List cost centers
requires authentication cost-center index
Lista plana ordenada por código, sem paginação. Cada item traz nível e caminho completo, para o cliente montar a árvore em memória.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cost-centers?q=vila&active=1" \
--header "Authorization: Bearer D1ac6hgfaEk4ePv6Vd358Zb" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers"
);
const params = {
"q": "vila",
"active": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer D1ac6hgfaEk4ePv6Vd358Zb",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "8673fee5-b39f-3251-88b3-e4dc3cda7c36",
"code": "633",
"name": "esse incidunt",
"level": 1,
"path": null,
"is_active": true,
"selectable": false,
"created_at": null,
"updated_at": null
},
{
"id": "d95c2c25-b631-362c-b684-3e5ee52d8143",
"code": "437",
"name": "asperiores repellendus",
"level": 1,
"path": null,
"is_active": true,
"selectable": false,
"created_at": null,
"updated_at": null
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show cost center
requires authentication cost-center show
Detalhe de um centro de custo
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/cost-centers/et" \
--header "Authorization: Bearer ha6bvDak15Pd38V4ecZfgE6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers/et"
);
const headers = {
"Authorization": "Bearer ha6bvDak15Pd38V4ecZfgE6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "842f8c73-ff7e-3f22-ab1a-f31f4d98dc37",
"code": "702",
"name": "non illo",
"level": 1,
"path": null,
"is_active": true,
"selectable": false,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create cost center
requires authentication cost-center store
Cadastra um centro de custo
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/cost-centers" \
--header "Authorization: Bearer Dk665bahE41a8Vf3dPgvZce" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"code\": \"Example Code\",
\"name\": \"Example Name\",
\"parent_id\": \"3f38abda-2066-378c-b780-5ae0332a927a\",
\"work_id\": \"2938c409-7cda-31a9-9be8-c65f0a70ca18\",
\"is_active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers"
);
const headers = {
"Authorization": "Bearer Dk665bahE41a8Vf3dPgvZce",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"code": "Example Code",
"name": "Example Name",
"parent_id": "3f38abda-2066-378c-b780-5ae0332a927a",
"work_id": "2938c409-7cda-31a9-9be8-c65f0a70ca18",
"is_active": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update cost center
requires authentication cost-center update
Atualiza um centro de custo, inclusive a situação (inativar e reativar)
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/cost-centers/modi" \
--header "Authorization: Bearer 5E6D6agvh8b3Pfk14cZaVed" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"code\": \"Example Code\",
\"name\": \"Example Name\",
\"parent_id\": \"f7deedff-10f7-372b-91a5-9bd7816d477d\",
\"work_id\": \"4c73ad01-0460-31a7-b70d-d5f5b6d45dc6\",
\"is_active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers/modi"
);
const headers = {
"Authorization": "Bearer 5E6D6agvh8b3Pfk14cZaVed",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"code": "Example Code",
"name": "Example Name",
"parent_id": "f7deedff-10f7-372b-91a5-9bd7816d477d",
"work_id": "4c73ad01-0460-31a7-b70d-d5f5b6d45dc6",
"is_active": true
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete cost center
requires authentication cost-center delete
Exclui um centro de custo. Só é permitido quando ele não tem centros abaixo nem lançamentos.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/cost-centers/nesciunt" \
--header "Authorization: Bearer 834akhebZgV56Ec1d6fDavP" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/cost-centers/nesciunt"
);
const headers = {
"Authorization": "Bearer 834akhebZgV56Ec1d6fDavP",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Customers
Endpoints for customers
List customers
requires authentication customers index
List all customers
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/customers?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Customer+name" \
--header "Authorization: Bearer 6DEeaZ6485hPdcfVakbg31v" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/customers"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Customer name",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 6DEeaZ6485hPdcfVakbg31v",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "68ca35c0-cac7-34e0-81ac-cdcae6fcca1f",
"name": "Srta. Catarina Rezende Vila Filho",
"email": "camilo98@example.net",
"phone": "(89) 91553-4936",
"document": "241.202.566-50",
"type": "pf",
"responsible": "Andressa Alcantara Perez",
"image": {
"id": null,
"url": null
},
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"documents_count": 0
},
{
"id": "3d944510-6dd8-3140-8b1f-2079b4eb5d57",
"name": "Dr. Santiago Rodrigues Filho",
"email": "rezende.vitor@example.net",
"phone": "(18) 92871-4757",
"document": "910.700.225-43",
"type": "pj",
"responsible": "Manuel Serrano Jr.",
"image": {
"id": null,
"url": null
},
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"documents_count": 0
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create customer
requires authentication customers store
Create a new customer
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/customers" \
--header "Authorization: Bearer eafvV8ag6Ek4bZ5h61PD3dc" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"email\": \"user@example.com\",
\"phone\": \"(11) 99999-9999\",
\"document\": \"Example Document\",
\"type\": \"Example Type\",
\"responsible\": \"Example Responsible\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"name\": \"Example Name\",
\"extension\": \"Example Image extension\",
\"size\": \"Example Image size\"
},
\"address\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"street\": \"Example Address street\",
\"number\": \"Example Address number\",
\"complement\": \"Example Address complement\",
\"neighborhood\": \"Example Address neighborhood\",
\"city\": \"Example Address city\",
\"state\": \"Example Address state\",
\"zip_code\": \"Example Address zip code\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/customers"
);
const headers = {
"Authorization": "Bearer eafvV8ag6Ek4bZ5h61PD3dc",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"email": "user@example.com",
"phone": "(11) 99999-9999",
"document": "Example Document",
"type": "Example Type",
"responsible": "Example Responsible",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"name": "Example Name",
"extension": "Example Image extension",
"size": "Example Image size"
},
"address": {
"0": "example1",
"1": "example2",
"street": "Example Address street",
"number": "Example Address number",
"complement": "Example Address complement",
"neighborhood": "Example Address neighborhood",
"city": "Example Address city",
"state": "Example Address state",
"zip_code": "Example Address zip code"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get customer
requires authentication customers index
Get a customer
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/customers/17" \
--header "Authorization: Bearer dfEcPe1k5b8DahV4Zv366ag" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/customers/17"
);
const headers = {
"Authorization": "Bearer dfEcPe1k5b8DahV4Zv366ag",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "8aa14ffa-3963-307d-8443-d9c70a878223",
"name": "Everton Rangel Marés",
"email": "rsanches@example.org",
"phone": "(94) 93843-8437",
"document": "427.537.457-65",
"type": "pj",
"responsible": "Sr. Márcio Benites",
"image": {
"id": null,
"url": null
},
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"documents_count": 0
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update customer
requires authentication customers update
Update a customer
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/customers/2" \
--header "Authorization: Bearer bd8D61fegPk43ahZVcE56av" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"email\": \"user@example.com\",
\"phone\": \"(11) 99999-9999\",
\"document\": \"Example Document\",
\"type\": \"Example Type\",
\"responsible\": \"Example Responsible\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"name\": \"Example Name\",
\"extension\": \"Example Image extension\",
\"size\": \"Example Image size\"
},
\"address\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"street\": \"Example Address street\",
\"number\": \"Example Address number\",
\"complement\": \"Example Address complement\",
\"neighborhood\": \"Example Address neighborhood\",
\"city\": \"Example Address city\",
\"state\": \"Example Address state\",
\"zip_code\": \"Example Address zip code\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/customers/2"
);
const headers = {
"Authorization": "Bearer bd8D61fegPk43ahZVcE56av",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"email": "user@example.com",
"phone": "(11) 99999-9999",
"document": "Example Document",
"type": "Example Type",
"responsible": "Example Responsible",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"name": "Example Name",
"extension": "Example Image extension",
"size": "Example Image size"
},
"address": {
"0": "example1",
"1": "example2",
"street": "Example Address street",
"number": "Example Address number",
"complement": "Example Address complement",
"neighborhood": "Example Address neighborhood",
"city": "Example Address city",
"state": "Example Address state",
"zip_code": "Example Address zip code"
}
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete customer
requires authentication customers delete
Delete a customer
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/customers/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer 6hZ83E6gbcDaPvVkdef4a15" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/customers/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer 6hZ83E6gbcDaPvVkdef4a15",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Daily Logs (RDO)
Endpoints for managing daily work reports (RDO)
List daily logs
requires authentication daily-log index
List all daily work reports (RDO)
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/daily-logs" \
--header "Authorization: Bearer Ee861Zgakh4cPbVf3D5dva6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"sort_by\": \"Example Sort by\",
\"sort_desc\": true,
\"page\": 1,
\"per_page\": 1,
\"q\": \"Example Q\",
\"work_id\": \"efc50cfd-9878-3c4f-ae63-fd553dee32e5\",
\"contract_id\": \"9060c42d-513c-3365-a524-5056807880be\",
\"status_id\": \"8a3f769c-9f54-304b-b46c-c774d6bf0fbe\",
\"filled_by\": \"988cf618-120c-36ed-bafa-86f15441a90c\",
\"responsible_id\": \"5ca50429-1b3f-3e89-81aa-c36b8741478c\",
\"date_from\": \"2024-01-01\",
\"date_to\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs"
);
const headers = {
"Authorization": "Bearer Ee861Zgakh4cPbVf3D5dva6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"sort_by": "Example Sort by",
"sort_desc": true,
"page": 1,
"per_page": 1,
"q": "Example Q",
"work_id": "efc50cfd-9878-3c4f-ae63-fd553dee32e5",
"contract_id": "9060c42d-513c-3365-a524-5056807880be",
"status_id": "8a3f769c-9f54-304b-b46c-c774d6bf0fbe",
"filled_by": "988cf618-120c-36ed-bafa-86f15441a90c",
"responsible_id": "5ca50429-1b3f-3e89-81aa-c36b8741478c",
"date_from": "2024-01-01",
"date_to": "2024-01-01"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "ee428e2f-ca17-3260-9357-9f4f6852ac28",
"code": "RDO-26-11-26",
"report_number": 1,
"date": "2026-11-26",
"status": {
"id": "a351a0d1-a5dc-44fe-ae28-5fb9beee0bf0",
"slug": null,
"name": null,
"abbreviation": "dolores",
"color": "#082c29",
"text_color": "#7bf73a"
},
"work": {
"id": "a351a0d1-9cda-4a7c-990c-5ecc9279132f",
"name": "Dr. Otávio Casanova",
"started_at": "2006-05-13 00:49:19"
},
"filled_by": {
"id": "a351a0d1-a21c-4116-b730-b1b9793f261f",
"name": "Sadye Jones"
},
"contract_number": "175/2026",
"deadline_at": "2027-11-26",
"technical_responsible": {
"name": null,
"certification": null,
"crea": null
},
"activities": [],
"occurrences": null,
"next_day_forecast": null,
"finalized_at": null,
"has_signed_document": false,
"content_hash": null,
"gov_br_validation_url": null,
"created_at": null,
"updated_at": null
},
{
"id": "965cd5fe-b79b-3b84-8493-5ed6ce32df46",
"code": "RDO-26-11-26",
"report_number": 1,
"date": "2026-11-26",
"status": {
"id": "a351a0d1-afc1-49ed-9b84-34b4cb4a6bb9",
"slug": null,
"name": null,
"abbreviation": "voluptatum",
"color": "#12de69",
"text_color": "#80e028"
},
"work": {
"id": "a351a0d1-aa31-4b54-af4f-9424f73759af",
"name": "Isaac Reis Valente Jr.",
"started_at": "1989-12-29 21:12:55"
},
"filled_by": {
"id": "a351a0d1-ae33-41ff-90e9-9a94d168d1d2",
"name": "Kaylah Barrows V"
},
"contract_number": "898/2026",
"deadline_at": "2027-11-26",
"technical_responsible": {
"name": null,
"certification": null,
"crea": null
},
"activities": [],
"occurrences": null,
"next_day_forecast": null,
"finalized_at": null,
"has_signed_document": false,
"content_hash": null,
"gov_br_validation_url": null,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Pending RDO days
requires authentication daily-log index
List the days in a period that have no RDO for a given work
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/daily-logs/pending-days" \
--header "Authorization: Bearer b346g6cZvPkda1EVhD8ae5f" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"contract_id\": \"Example Contract id\",
\"date_from\": \"2024-01-01\",
\"date_to\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/pending-days"
);
const headers = {
"Authorization": "Bearer b346g6cZvPkda1EVhD8ae5f",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"contract_id": "Example Contract id",
"date_from": "2024-01-01",
"date_to": "2024-01-01"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
"2026-07-01",
"2026-07-02"
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show daily log
requires authentication daily-log show
Show a daily work report (RDO)
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/daily-logs/ut" \
--header "Authorization: Bearer 6ZbadPVka3D5v1cfh4e68gE" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/ut"
);
const headers = {
"Authorization": "Bearer 6ZbadPVka3D5v1cfh4e68gE",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "83ca992c-0c6c-37d4-ba29-bd7c6037207c",
"code": "RDO-26-11-26",
"report_number": 1,
"date": "2026-11-26",
"status": {
"id": "a351a0d1-c8d0-48c5-8c32-10993eaee796",
"slug": null,
"name": null,
"abbreviation": "ipsa",
"color": "#849ac6",
"text_color": "#f99f26"
},
"work": {
"id": "a351a0d1-c274-430c-b3c0-cb6686fbfeb0",
"name": "Dr. Danielle Burgos Grego Jr.",
"started_at": "1983-04-08 16:29:51"
},
"filled_by": {
"id": "a351a0d1-c6dd-4e3c-abe7-ecac8cdcd16d",
"name": "Mariano Lueilwitz Jr."
},
"contract_number": "915/2026",
"deadline_at": "2027-11-26",
"technical_responsible": {
"name": null,
"certification": null,
"crea": null
},
"activities": [],
"occurrences": null,
"next_day_forecast": null,
"finalized_at": null,
"has_signed_document": false,
"content_hash": null,
"gov_br_validation_url": null,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create daily log
requires authentication daily-log store
Open a new daily work report (RDO) for a work
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/daily-logs" \
--header "Authorization: Bearer 6e8Ed6bZ3Pfaka1g4hc5vDV" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"contract_id\": \"Example Contract id\",
\"date\": \"2024-01-01\",
\"status_id\": \"cfb57250-e9a8-3123-b6e6-250b387263b3\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs"
);
const headers = {
"Authorization": "Bearer 6e8Ed6bZ3Pfaka1g4hc5vDV",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"contract_id": "Example Contract id",
"date": "2024-01-01",
"status_id": "cfb57250-e9a8-3123-b6e6-250b387263b3"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update daily log
requires authentication daily-log update
Update a draft RDO: weather, team, activities, occurrences and next-day forecast
Example request:
curl --request PATCH \
"https://api.bs-homolog.pensou.app.br/api/daily-logs/tempore" \
--header "Authorization: Bearer eEaf6V85v6k1Ddh4ab3cZPg" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"activities\": \"Example Activities\",
\"occurrences\": \"Example Occurrences\",
\"next_day_forecast\": \"Example Next day forecast\",
\"weather\": [
{
\"shift\": \"Example Weather * shift\",
\"weather\": \"Example Weather * weather\"
},
null
],
\"teams\": [
{
\"employee_role_id\": \"70c6635f-d098-4b47-9ed8-ee9522efe6df\",
\"quantity\": 1
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/tempore"
);
const headers = {
"Authorization": "Bearer eEaf6V85v6k1Ddh4ab3cZPg",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"activities": "Example Activities",
"occurrences": "Example Occurrences",
"next_day_forecast": "Example Next day forecast",
"weather": [
{
"shift": "Example Weather * shift",
"weather": "Example Weather * weather"
},
null
],
"teams": [
{
"employee_role_id": "70c6635f-d098-4b47-9ed8-ee9522efe6df",
"quantity": 1
},
null
]
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Finalize daily log
requires authentication daily-log finalize
Validate, stamp and lock a draft RDO (Rascunho → Finalizado)
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/daily-logs/qui/finalize" \
--header "Authorization: Bearer c8ZbaDh5fkE6Pa14d63vgVe" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/qui/finalize"
);
const headers = {
"Authorization": "Bearer c8ZbaDh5fkE6Pa14d63vgVe",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Attach gov.br signed document
requires authentication daily-log finalize
Attach the gov.br-signed PDF and validation link to a finalized RDO
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/daily-logs/modi/signed-document" \
--header "Authorization: Bearer aEZ5hk66v3eaPd8gV4Dfcb1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"path\": \"Example Path\",
\"name\": \"Example Name\",
\"size\": \"Example Size\",
\"extension\": \"Example Extension\",
\"gov_br_validation_url\": \"https:\\/\\/example.com\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/modi/signed-document"
);
const headers = {
"Authorization": "Bearer aEZ5hk66v3eaPd8gV4Dfcb1",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"path": "Example Path",
"name": "Example Name",
"size": "Example Size",
"extension": "Example Extension",
"gov_br_validation_url": "https:\/\/example.com"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Reopen daily log
requires authentication daily-log reopen
Send a finalized RDO back to draft (Finalizado → Rascunho). Refused when a gov.br-signed document is attached
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/daily-logs/ad/reopen" \
--header "Authorization: Bearer eh8bDZc65dVv1kaE63gaf4P" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/ad/reopen"
);
const headers = {
"Authorization": "Bearer eh8bDZc65dVv1kaE63gaf4P",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Attach photos
requires authentication daily-log update
Attach photographs (already uploaded to storage) to a draft RDO
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/daily-logs/sint/photos" \
--header "Authorization: Bearer 5gkecDvhfZ1a3Eba86d6PV4" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"photos\": [
{
\"path\": \"Example Photos * path\",
\"name\": \"Example Name\",
\"size\": \"Example Photos * size\",
\"extension\": \"Example Photos * extension\",
\"caption\": \"Example Photos * caption\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/sint/photos"
);
const headers = {
"Authorization": "Bearer 5gkecDvhfZ1a3Eba86d6PV4",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"photos": [
{
"path": "Example Photos * path",
"name": "Example Name",
"size": "Example Photos * size",
"extension": "Example Photos * extension",
"caption": "Example Photos * caption"
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update photo caption
requires authentication daily-log update
Update the caption of a photo in a draft RDO
Example request:
curl --request PATCH \
"https://api.bs-homolog.pensou.app.br/api/daily-logs/temporibus/photos/quisquam" \
--header "Authorization: Bearer 6cedhkZ3E4PgvDVa6185baf" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"caption\": \"Example Caption\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/temporibus/photos/quisquam"
);
const headers = {
"Authorization": "Bearer 6cedhkZ3E4PgvDVa6185baf",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"caption": "Example Caption"
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete photo
requires authentication daily-log update
Remove a photo from a draft RDO
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/daily-logs/molestias/photos/voluptatem" \
--header "Authorization: Bearer Pdeh51kVvZf86a4cabg3DE6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/molestias/photos/voluptatem"
);
const headers = {
"Authorization": "Bearer Pdeh51kVvZf86a4cabg3DE6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete daily log
requires authentication daily-log delete
Delete a draft daily work report (RDO)
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/daily-logs/est" \
--header "Authorization: Bearer kgV6138ehDfaEc4bdZPa6v5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/daily-logs/est"
);
const headers = {
"Authorization": "Bearer kgV6138ehDfaEc4bdZPa6v5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Disciplines
Endpoints for engineering disciplines
List disciplines
requires authentication discipline index
List all disciplines
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/disciplines?q=El%C3%A9trico&active=1" \
--header "Authorization: Bearer kaafVh1DbEv8dZe43P6c56g" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/disciplines"
);
const params = {
"q": "Elétrico",
"active": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer kaafVh1DbEv8dZe43P6c56g",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "a70cd72e-cdbc-34e4-a577-9450fbab98e2",
"name": "Maiores",
"code": "GEA",
"description": "Cupiditate voluptatem et nulla ratione sit sunt maiores.",
"active": true
},
{
"id": "387b10df-e829-3c9e-ba52-7f7087747fb1",
"name": "Officia",
"code": "ELF",
"description": "Aut et nulla saepe non sit.",
"active": true
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show discipline
requires authentication discipline show
Show a discipline
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/disciplines/1" \
--header "Authorization: Bearer Vc6136kE5Pvdbg4Za8Defha" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/disciplines/1"
);
const headers = {
"Authorization": "Bearer Vc6136kE5Pvdbg4Za8Defha",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "94b21288-6d2b-3ad7-9d5b-ac97ba2349a3",
"name": "Et",
"code": "EXK",
"description": "Perferendis consequatur non velit iusto.",
"active": true
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create discipline
requires authentication discipline store
Create a new discipline
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/disciplines" \
--header "Authorization: Bearer ehgfd3a6Da564ZEVvbc8Pk1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"code\": \"Example Code\",
\"description\": \"Example Description\",
\"active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/disciplines"
);
const headers = {
"Authorization": "Bearer ehgfd3a6Da564ZEVvbc8Pk1",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"code": "Example Code",
"description": "Example Description",
"active": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update discipline
requires authentication discipline update
Update a discipline
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/disciplines/1" \
--header "Authorization: Bearer ghcf4EdbD16Z3kv65aaP8eV" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"code\": \"Example Code\",
\"description\": \"Example Description\",
\"active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/disciplines/1"
);
const headers = {
"Authorization": "Bearer ghcf4EdbD16Z3kv65aaP8eV",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"code": "Example Code",
"description": "Example Description",
"active": true
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete discipline
requires authentication discipline delete
Delete a discipline
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/disciplines/cupiditate" \
--header "Authorization: Bearer 1kaD8abc3vdZgfEehP6645V" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/disciplines/cupiditate"
);
const headers = {
"Authorization": "Bearer 1kaD8abc3vdZgfEehP6645V",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Document Categories
Endpoints for document categories
List document categories
requires authentication document-category index
List all document categories
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/document-categories?q=Contracts&module=employee" \
--header "Authorization: Bearer Dcdef435ag6V1bZkaEvhP86" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/document-categories"
);
const params = {
"q": "Contracts",
"module": "employee",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer Dcdef435ag6V1bZkaEvhP86",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "e40b876d-0713-39de-a5bf-50fdd71ff6a2",
"name": "Dr. Luísa Eduarda Toledo Filho",
"description": "Molestiae non veniam iste at quia est unde. Aut adipisci nemo aut aut consequuntur similique. Molestias qui atque ut.",
"module": "document"
},
{
"id": "a0ead5e2-5fa3-3be8-bf6a-fe3d0c71a1d0",
"name": "Sr. Cristiano Rangel Branco",
"description": "Quisquam eligendi id et ad et. Commodi saepe ullam illo voluptatum occaecati. Deleniti accusantium aspernatur esse saepe perspiciatis labore tenetur.",
"module": "document"
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show document category
requires authentication document-category show
Show a document category
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/document-categories/sunt" \
--header "Authorization: Bearer 1dvgh8Z6Pecfa5b3Da4VEk6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/document-categories/sunt"
);
const headers = {
"Authorization": "Bearer 1dvgh8Z6Pecfa5b3Da4VEk6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "fba42d24-8a84-3e5a-8cf7-149b2dc96d9f",
"name": "Rogério Campos Campos Sobrinho",
"description": "Corporis eum laudantium consectetur tenetur est. Recusandae sint quasi harum ut est. Vel sit et dolores voluptatem molestias.",
"module": "document"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create document category
requires authentication document-category store
Create a new document category
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/document-categories" \
--header "Authorization: Bearer gZd316bkePVDE46vhfac85a" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"module\": \"Example Module\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/document-categories"
);
const headers = {
"Authorization": "Bearer gZd316bkePVDE46vhfac85a",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"module": "Example Module"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update document category
requires authentication document-category update
Update a document category
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/document-categories/ut" \
--header "Authorization: Bearer P6b6gvaedhf153ZDE8akcV4" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"module\": \"Example Module\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/document-categories/ut"
);
const headers = {
"Authorization": "Bearer P6b6gvaedhf153ZDE8akcV4",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"module": "Example Module"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete document category
requires authentication document-category delete
Delete a document category
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/document-categories/autem" \
--header "Authorization: Bearer E6hV15a4daebfg3ZcD8kP6v" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/document-categories/autem"
);
const headers = {
"Authorization": "Bearer E6hV15a4daebfg3ZcD8kP6v",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Documents
Endpoints for documents
List documents
requires authentication documents index
List all documents
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/documents?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Document+name&categories[]=sint&documentable_type=nemo&customers[]=vel&suppliers[]=a" \
--header "Authorization: Bearer 4dh8ZcPvDak56e1bVf6aEg3" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/documents"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Document name",
"categories[0]": "sint",
"documentable_type": "nemo",
"customers[0]": "vel",
"suppliers[0]": "a",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 4dh8ZcPvDak56e1bVf6aEg3",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "47e363bf-0aef-3e09-8f42-c872470f262e",
"name": "Gilberto Rafael Santana",
"file": {
"id": null,
"url": null,
"extension": null
},
"created_at": null,
"updated_at": null
},
{
"id": "5b46834e-37b3-30f1-a1b7-cac2cb5fbeee",
"name": "Sr. Mário Luiz Ávila",
"file": {
"id": null,
"url": null,
"extension": null
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get document
requires authentication documents show
Get a document
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/documents/18" \
--header "Authorization: Bearer 6hgE4ebvVa3Ddakfc5P861Z" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/documents/18"
);
const headers = {
"Authorization": "Bearer 6hgE4ebvVa3Ddakfc5P861Z",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "78e5d5ea-5457-3d7f-bc12-1af4ed17a490",
"name": "Carla Meireles Domingues Neto",
"file": {
"id": null,
"url": null,
"extension": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create document
requires authentication documents store
Create a new document
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/documents" \
--header "Authorization: Bearer kgd658DV1ech3vZf64aEPba" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"category_id\": \"b101c68c-5044-3a02-87ac-3a581b2fb7ae\",
\"file\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example File path\",
\"name\": \"Example Name\",
\"extension\": \"Example File extension\",
\"size\": \"Example File size\"
},
\"documentable_type\": \"Example Documentable type\",
\"documentable_id\": \"Example Documentable id\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/documents"
);
const headers = {
"Authorization": "Bearer kgd658DV1ech3vZf64aEPba",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"category_id": "b101c68c-5044-3a02-87ac-3a581b2fb7ae",
"file": {
"0": "example1",
"1": "example2",
"path": "Example File path",
"name": "Example Name",
"extension": "Example File extension",
"size": "Example File size"
},
"documentable_type": "Example Documentable type",
"documentable_id": "Example Documentable id"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update document
requires authentication documents update
Update a document
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/documents/12" \
--header "Authorization: Bearer aVv4fEb36ceD5d86ZaPkhg1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"category_id\": \"b5d859b8-b70f-3585-ae01-2edae2b23052\",
\"file\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example File path\",
\"name\": \"Example Name\",
\"extension\": \"Example File extension\",
\"size\": \"Example File size\"
},
\"documentable_type\": \"Example Documentable type\",
\"documentable_id\": \"Example Documentable id\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/documents/12"
);
const headers = {
"Authorization": "Bearer aVv4fEb36ceD5d86ZaPkhg1",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"category_id": "b5d859b8-b70f-3585-ae01-2edae2b23052",
"file": {
"0": "example1",
"1": "example2",
"path": "Example File path",
"name": "Example Name",
"extension": "Example File extension",
"size": "Example File size"
},
"documentable_type": "Example Documentable type",
"documentable_id": "Example Documentable id"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete document
requires authentication documents delete
Delete a document
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/documents/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer 8ZvaVfeb6EdPga5413cDh6k" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/documents/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer 8ZvaVfeb6EdPga5413cDh6k",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
EPI Renewals
Endpoints for EPI pending renewals
List EPI renewals
requires authentication employee-epi index
List pending/ignored (default) or completed EPI renewals. Ignored items remain in the default listing with renewal_status=ignored
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/epi-renewals" \
--header "Authorization: Bearer c386h4EZP65f1aDkVvdbaeg" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"q\": \"qui\",
\"renewal_status\": \"pending\",
\"urgency\": \"expired\",
\"employee_id\": \"rerum\",
\"epi_type_id\": \"quo\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-renewals"
);
const headers = {
"Authorization": "Bearer c386h4EZP65f1aDkVvdbaeg",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"q": "qui",
"renewal_status": "pending",
"urgency": "expired",
"employee_id": "rerum",
"epi_type_id": "quo"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
EPI renewals summary
requires authentication employee-epi index
Counts of renewals by urgency (pending and ignored; ignore only silences notifications)
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/epi-renewals/summary" \
--header "Authorization: Bearer 58f3a4gbEc6PeZ6kavd1VDh" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-renewals/summary"
);
const headers = {
"Authorization": "Bearer 58f3a4gbEc6PeZ6kavd1VDh",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Renew EPI delivery
requires authentication employee-epi update
Renew an EPI delivery with a new delivery date
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/epi-renewals/sit/renew" \
--header "Authorization: Bearer 4PV5Eaa8fck6bg1vD6ehZ3d" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"quantity\": 1,
\"condition\": \"new\",
\"confirm_insufficient_stock\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-renewals/sit/renew"
);
const headers = {
"Authorization": "Bearer 4PV5Eaa8fck6bg1vD6ehZ3d",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"quantity": 1,
"condition": "new",
"confirm_insufficient_stock": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Ignore EPI renewal
requires authentication employee-epi update
Ignore expiry alerts for an EPI delivery
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/epi-renewals/aut/ignore" \
--header "Authorization: Bearer g38E6dcbah5afZvPVDe46k1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"ignore_reason\": \"Colaborador afastado temporariamente\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-renewals/aut/ignore"
);
const headers = {
"Authorization": "Bearer g38E6dcbah5afZvPVDe46k1",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"ignore_reason": "Colaborador afastado temporariamente"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Unignore EPI renewal
requires authentication employee-epi update
Resume expiry alerts for an EPI delivery
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/epi-renewals/qui/ignore" \
--header "Authorization: Bearer Ed5ga1P6ckD8be6a4VZv3fh" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-renewals/qui/ignore"
);
const headers = {
"Authorization": "Bearer Ed5ga1P6ckD8be6a4VZv3fh",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
EPI Types
Endpoints for EPI types catalog
List EPI types
requires authentication epi index
List all EPI types
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/epi-types" \
--header "Authorization: Bearer 4DkfEVgv3Zaba56e6h1dcP8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"q\": \"voluptates\",
\"stock_id\": \"ut\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-types"
);
const headers = {
"Authorization": "Bearer 4DkfEVgv3Zaba56e6h1dcP8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"q": "voluptates",
"stock_id": "ut"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "38e20bda-809f-3543-9c9c-c36a5133bba4",
"name": "officia officia",
"default_validity_days": 350,
"requires_signature": true,
"numero_ca": "13484",
"product": null,
"available_quantity": null,
"created_at": null,
"updated_at": null
},
{
"id": "014c2685-f507-3305-a10f-395f9d94dd1b",
"name": "ut magnam",
"default_validity_days": 412,
"requires_signature": true,
"numero_ca": "34938",
"product": null,
"available_quantity": null,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List catalog products that could become EPI
requires authentication epi index
Products sitting in a family flagged as EPI that do not have EPI attributes yet. Being here does not make a product an EPI: it becomes one when someone gives it a validity, through the create endpoint with action link_existing.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/epi-types/candidates" \
--header "Authorization: Bearer akv684VcP6ZbhD13f5aEdge" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"q\": \"et\",
\"stock_id\": \"enim\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-types/candidates"
);
const headers = {
"Authorization": "Bearer akv684VcP6ZbhD13f5aEdge",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"q": "et",
"stock_id": "enim"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show EPI type
requires authentication epi show
Show an EPI type
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/epi-types/laudantium" \
--header "Authorization: Bearer hg3bEfVa66kaeD5c1Z8dPv4" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-types/laudantium"
);
const headers = {
"Authorization": "Bearer hg3bEfVa66kaeD5c1Z8dPv4",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "96ba4e2b-169d-38cd-a3f6-1758ad0dfca2",
"name": "cum eveniet",
"default_validity_days": 617,
"requires_signature": false,
"numero_ca": "35247",
"product": null,
"available_quantity": null,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create EPI type
requires authentication epi store
Create a new EPI type
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/epi-types" \
--header "Authorization: Bearer aag3dEePhf1bDV8kZ65c46v" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"default_validity_days\": 1,
\"requires_signature\": true,
\"numero_ca\": \"Example Numero ca\",
\"action\": \"Example Action\",
\"product_id\": \"cedf37f4-831f-324c-8494-0b26eaf044f8\",
\"product_family_id\": \"6e2fa23a-c493-3b9d-b1c7-6316ea067245\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-types"
);
const headers = {
"Authorization": "Bearer aag3dEePhf1bDV8kZ65c46v",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"default_validity_days": 1,
"requires_signature": true,
"numero_ca": "Example Numero ca",
"action": "Example Action",
"product_id": "cedf37f4-831f-324c-8494-0b26eaf044f8",
"product_family_id": "6e2fa23a-c493-3b9d-b1c7-6316ea067245"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Link EPI types to catalog products in bulk
requires authentication epi update
Link several EPI types to catalog products at once, creating the product where it does not exist yet. All or nothing: one refusal rolls back the whole batch.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/epi-types/link-products" \
--header "Authorization: Bearer D6afP4c6bh3Zd5EgaekV1v8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
{
\"epi_type_id\": \"78667339-680e-36e9-b8da-5b7f6c5845bd\",
\"action\": \"Example Items * action\",
\"product_id\": \"7e44ad1c-768c-3f2a-a6d5-cbcd39b6bfe1\",
\"product_family_id\": \"4804d305-bfb1-3a49-9e6d-95ce2dbdfc23\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-types/link-products"
);
const headers = {
"Authorization": "Bearer D6afP4c6bh3Zd5EgaekV1v8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
{
"epi_type_id": "78667339-680e-36e9-b8da-5b7f6c5845bd",
"action": "Example Items * action",
"product_id": "7e44ad1c-768c-3f2a-a6d5-cbcd39b6bfe1",
"product_family_id": "4804d305-bfb1-3a49-9e6d-95ce2dbdfc23"
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Link an EPI type to a catalog product
requires authentication epi update
Link one EPI type to an existing product, or create the product from the EPI type name.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/epi-types/voluptatibus/product" \
--header "Authorization: Bearer b6e3VP81cfkD6gaaE4dZ5hv" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"action\": \"Example Action\",
\"product_id\": \"fbf002c9-0088-3ddf-8641-3ff78e7223e3\",
\"product_family_id\": \"7f480bea-f4fc-3dbd-8a8f-676382942f80\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-types/voluptatibus/product"
);
const headers = {
"Authorization": "Bearer b6e3VP81cfkD6gaaE4dZ5hv",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"action": "Example Action",
"product_id": "fbf002c9-0088-3ddf-8641-3ff78e7223e3",
"product_family_id": "7f480bea-f4fc-3dbd-8a8f-676382942f80"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update EPI type
requires authentication epi update
Update an EPI type
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/epi-types/est" \
--header "Authorization: Bearer vdP63chf1ZgEeDakba5486V" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"default_validity_days\": 1,
\"requires_signature\": true,
\"numero_ca\": \"Example Numero ca\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-types/est"
);
const headers = {
"Authorization": "Bearer vdP63chf1ZgEeDakba5486V",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"default_validity_days": 1,
"requires_signature": true,
"numero_ca": "Example Numero ca"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete EPI type
requires authentication epi delete
Delete an EPI type
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/epi-types/soluta" \
--header "Authorization: Bearer hf4PVE6dv6Zk3a81gDbec5a" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-types/soluta"
);
const headers = {
"Authorization": "Bearer hf4PVE6dv6Zk3a81gDbec5a",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Employee Roles
Endpoints for employee roles
List employee roles
requires authentication employee-role index
List all employee roles
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employee-roles?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Manager" \
--header "Authorization: Bearer 5Ef4agbDVd8Pe136a6kvchZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employee-roles"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Manager",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 5Ef4agbDVd8Pe136a6kvchZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "17104e16-263b-462c-8f49-c5b69a52a5ea",
"name": "excepturi",
"description": null,
"created_at": null,
"updated_at": null
},
{
"id": "598ab514-8b7e-4201-882f-07ad748b9443",
"name": "quasi",
"description": null,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show employee role
requires authentication employee-role show
Show an employee role
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employee-roles/ut" \
--header "Authorization: Bearer 5P4cvadE6ka6Df13Zehg8bV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employee-roles/ut"
);
const headers = {
"Authorization": "Bearer 5P4cvadE6ka6Df13Zehg8bV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "21a0424c-e2a3-4e6d-a8d8-14f620ac64c1",
"name": "ut",
"description": null,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create employee role
requires authentication employee-role store
Create a new employee role
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employee-roles" \
--header "Authorization: Bearer 4hDgdc8Z6Eak6Pa5be1Vvf3" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employee-roles"
);
const headers = {
"Authorization": "Bearer 4hDgdc8Z6Eak6Pa5be1Vvf3",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update employee role
requires authentication employee-role update
Update an employee role
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/employee-roles/rem" \
--header "Authorization: Bearer vdbZ8a661VPkaefc3hD4gE5" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employee-roles/rem"
);
const headers = {
"Authorization": "Bearer vdbZ8a661VPkaefc3hD4gE5",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete employee role
requires authentication employee-role delete
Delete an employee role
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/employee-roles/cupiditate" \
--header "Authorization: Bearer v6DaPc4khEZ1ed5a68g3bfV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employee-roles/cupiditate"
);
const headers = {
"Authorization": "Bearer v6DaPc4khEZ1ed5a68g3bfV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Employees
Endpoints for employees
List EPI terms
requires authentication employee-epi index
List initial EPI kit terms globally
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/epi-terms" \
--header "Authorization: Bearer g3416Vkhbav8eDdEc6Pa5Zf" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"sort_by\": \"delivery_date\",
\"sort_desc\": true,
\"page\": 37,
\"per_page\": 14,
\"q\": \"quae\",
\"employee_id\": \"laborum\",
\"has_term\": false
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/epi-terms"
);
const headers = {
"Authorization": "Bearer g3416Vkhbav8eDdEc6Pa5Zf",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"sort_by": "delivery_date",
"sort_desc": true,
"page": 37,
"per_page": 14,
"q": "quae",
"employee_id": "laborum",
"has_term": false
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List employees
requires authentication employee index
List all employees
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Jo%C3%A3o+Silva&status=active&employee_roles[]=et&admission_date_from=2026-01-01&admission_date_to=2026-12-31" \
--header "Authorization: Bearer 3kcVh16f64veZgdPa8EDab5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "João Silva",
"status": "active",
"employee_roles[0]": "et",
"admission_date_from": "2026-01-01",
"admission_date_to": "2026-12-31",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 3kcVh16f64veZgdPa8EDab5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "0b37fce4-c56b-464e-9068-f9702f36d9bd",
"name": "Dr. Everton Nero Pontes Sobrinho",
"cpf": "571.240.813-68",
"rg": null,
"ctps": null,
"phone": null,
"birthdate": "1978-08-26",
"email": "eespinoza@example.net",
"pis_pasep": null,
"admission_date": "2015-03-29",
"daily_salary": null,
"monthly_salary": null,
"nationality": "Madagascar",
"place_of_birth": "Téo do Sul",
"status": "active",
"status_label": "Ativo",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"employee_role": {
"id": "a351a0d2-6923-4f29-9351-09c31545c0c2",
"name": "est"
},
"created_at": null,
"updated_at": null
},
{
"id": "4f2888ab-ec3d-4eac-ad56-480710b64562",
"name": "Thiago Vasques Neto",
"cpf": "254.675.549-75",
"rg": null,
"ctps": "559891527",
"phone": null,
"birthdate": "1970-09-17",
"email": null,
"pis_pasep": null,
"admission_date": "1977-03-14",
"daily_salary": "117.48",
"monthly_salary": null,
"nationality": "Uruguai",
"place_of_birth": "Heitor do Norte",
"status": "active",
"status_label": "Ativo",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"employee_role": {
"id": "a351a0d2-6e8c-4b67-9306-35362abc716a",
"name": "dolores"
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": "/?page=36",
"next": null
},
"meta": {
"current_page": 37,
"from": 361,
"last_page": 1,
"links": [
{
"url": "/?page=36",
"label": "« Anterior",
"page": 36,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": false
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 362,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Export employees to Excel
requires authentication employee export
Dispatches async Excel generation using the same filters as the listing. Frontend is notified via Pusher when ready.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/excel?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Jo%C3%A3o+Silva&status=active&employee_roles[]=blanditiis&admission_date_from=2026-01-01&admission_date_to=2026-12-31" \
--header "Authorization: Bearer Pa3vb6E856Dfke14hZVdcga" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/excel"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "João Silva",
"status": "active",
"employee_roles[0]": "blanditiis",
"admission_date_from": "2026-01-01",
"admission_date_to": "2026-12-31",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer Pa3vb6E856Dfke14hZVdcga",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (202):
{
"message": "string",
"channel": "string",
"event": "string"
}
Example response (422):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show employee
requires authentication employee show
Show an employee
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/16" \
--header "Authorization: Bearer bvZ5DcV6Pf4gka1e6h3ad8E" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/16"
);
const headers = {
"Authorization": "Bearer bvZ5DcV6Pf4gka1e6h3ad8E",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "9bcce1e7-9c50-4ef2-941c-1cf9347e96a4",
"name": "Denis Cruz Gonçalves",
"cpf": "340.064.714-22",
"rg": null,
"ctps": "269198966",
"phone": null,
"birthdate": null,
"email": "santacruz.willian@example.org",
"pis_pasep": null,
"admission_date": "1971-01-30",
"daily_salary": null,
"monthly_salary": null,
"nationality": null,
"place_of_birth": null,
"status": "active",
"status_label": "Ativo",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"employee_role": {
"id": "a351a0d2-7ac8-411e-8b8c-8e4daa6c4703",
"name": "est"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create employee
requires authentication employee store
Create a new employee
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employees" \
--header "Authorization: Bearer agh34b6Ed1V6ckv8eDZPa5f" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"cpf\": \"Example Cpf\",
\"rg\": \"Example Rg\",
\"ctps\": \"Example Ctps\",
\"phone\": \"(11) 99999-9999\",
\"birthdate\": \"2024-01-01\",
\"email\": \"user@example.com\",
\"employee_role_id\": \"a131b812-06ef-4dd8-803a-d430e555cc02\",
\"pis_pasep\": \"Example Pis pasep\",
\"admission_date\": \"2024-01-01\",
\"daily_salary\": 1,
\"monthly_salary\": 1,
\"nationality\": \"Example Nationality\",
\"place_of_birth\": \"Example Place of birth\",
\"address\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"street\": \"Example Address street\",
\"number\": \"Example Address number\",
\"complement\": \"Example Address complement\",
\"neighborhood\": \"Example Address neighborhood\",
\"city\": \"Example Address city\",
\"state\": \"Example Address state\",
\"zip_code\": \"Example Address zip code\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees"
);
const headers = {
"Authorization": "Bearer agh34b6Ed1V6ckv8eDZPa5f",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"cpf": "Example Cpf",
"rg": "Example Rg",
"ctps": "Example Ctps",
"phone": "(11) 99999-9999",
"birthdate": "2024-01-01",
"email": "user@example.com",
"employee_role_id": "a131b812-06ef-4dd8-803a-d430e555cc02",
"pis_pasep": "Example Pis pasep",
"admission_date": "2024-01-01",
"daily_salary": 1,
"monthly_salary": 1,
"nationality": "Example Nationality",
"place_of_birth": "Example Place of birth",
"address": {
"0": "example1",
"1": "example2",
"street": "Example Address street",
"number": "Example Address number",
"complement": "Example Address complement",
"neighborhood": "Example Address neighborhood",
"city": "Example Address city",
"state": "Example Address state",
"zip_code": "Example Address zip code"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "11d40bfa-c0e6-446f-9739-a06667a70a81",
"name": "Sr. Emiliano Mascarenhas Serna Neto",
"cpf": "222.133.735-35",
"rg": "174283096",
"ctps": "897449853",
"phone": null,
"birthdate": null,
"email": "zpadilha@example.com",
"pis_pasep": "93507001609",
"admission_date": "2023-10-03",
"daily_salary": "277.22",
"monthly_salary": null,
"nationality": "Tanzânia",
"place_of_birth": "Wellington d'Oeste",
"status": "active",
"status_label": "Ativo",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"employee_role": {
"id": "a351a0d2-845b-4ad8-814d-175512ac550c",
"name": "iure"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update employee
requires authentication employee update
Update an employee
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/employees/13" \
--header "Authorization: Bearer ev46aZkhbdag8PV6Ef1c53D" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"cpf\": \"Example Cpf\",
\"rg\": \"Example Rg\",
\"ctps\": \"Example Ctps\",
\"phone\": \"(11) 99999-9999\",
\"birthdate\": \"2024-01-01\",
\"email\": \"user@example.com\",
\"employee_role_id\": \"c24fdc3d-b7c2-47d5-bf43-bffc0021d4b8\",
\"pis_pasep\": \"Example Pis pasep\",
\"admission_date\": \"2024-01-01\",
\"daily_salary\": 1,
\"monthly_salary\": 1,
\"nationality\": \"Example Nationality\",
\"place_of_birth\": \"Example Place of birth\",
\"address\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"street\": \"Example Address street\",
\"number\": \"Example Address number\",
\"complement\": \"Example Address complement\",
\"neighborhood\": \"Example Address neighborhood\",
\"city\": \"Example Address city\",
\"state\": \"Example Address state\",
\"zip_code\": \"Example Address zip code\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/13"
);
const headers = {
"Authorization": "Bearer ev46aZkhbdag8PV6Ef1c53D",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"cpf": "Example Cpf",
"rg": "Example Rg",
"ctps": "Example Ctps",
"phone": "(11) 99999-9999",
"birthdate": "2024-01-01",
"email": "user@example.com",
"employee_role_id": "c24fdc3d-b7c2-47d5-bf43-bffc0021d4b8",
"pis_pasep": "Example Pis pasep",
"admission_date": "2024-01-01",
"daily_salary": 1,
"monthly_salary": 1,
"nationality": "Example Nationality",
"place_of_birth": "Example Place of birth",
"address": {
"0": "example1",
"1": "example2",
"street": "Example Address street",
"number": "Example Address number",
"complement": "Example Address complement",
"neighborhood": "Example Address neighborhood",
"city": "Example Address city",
"state": "Example Address state",
"zip_code": "Example Address zip code"
}
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Dismiss employee
requires authentication employee employment
Register the dismissal of an active employee
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employees/019556e7-2e9f-777c-a177-30bbf0646c32/dismiss" \
--header "Authorization: Bearer aEhvd4cbD68kV3g5Pf1ea6Z" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"dismissal_date\": \"2026-11-26\",
\"dismissal_reason\": \"resignation\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/019556e7-2e9f-777c-a177-30bbf0646c32/dismiss"
);
const headers = {
"Authorization": "Bearer aEhvd4cbD68kV3g5Pf1ea6Z",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"dismissal_date": "2026-11-26",
"dismissal_reason": "resignation"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "4477c8b9-ef84-454c-b9dc-821be3f2e9b0",
"name": "Dr. Renan Richard Neves",
"cpf": "682.326.572-04",
"rg": "636695417",
"ctps": null,
"phone": "(75) 3893-4322",
"birthdate": "1983-09-25",
"email": null,
"pis_pasep": null,
"admission_date": "1997-06-25",
"daily_salary": null,
"monthly_salary": "6115.24",
"nationality": "República Centroafricana",
"place_of_birth": "Rangel d'Oeste",
"status": "active",
"status_label": "Ativo",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"employee_role": {
"id": "a351a0d2-9381-47a2-a62f-1b3034168c0f",
"name": "aliquam"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Rehire employee
requires authentication employee employment
Rehire an inactive employee with a new admission date
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employees/019556e7-2e9f-777c-a177-30bbf0646c32/rehire" \
--header "Authorization: Bearer 6bekgPvZfh4dV8a3caE5D61" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"admission_date\": \"2026-11-26\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/019556e7-2e9f-777c-a177-30bbf0646c32/rehire"
);
const headers = {
"Authorization": "Bearer 6bekgPvZfh4dV8a3caE5D61",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"admission_date": "2026-11-26"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "669e5005-54ea-4d6d-8786-944d37606668",
"name": "Bárbara Vasques",
"cpf": "356.777.250-61",
"rg": "942517099",
"ctps": "493316319",
"phone": "(42) 94317-0625",
"birthdate": null,
"email": null,
"pis_pasep": null,
"admission_date": "1975-10-18",
"daily_salary": "116.73",
"monthly_salary": null,
"nationality": null,
"place_of_birth": null,
"status": "active",
"status_label": "Ativo",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"employee_role": {
"id": "a351a0d2-99de-4193-b9c8-0b3289c93b2a",
"name": "magnam"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete employee
requires authentication employee delete
Delete an employee
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/employees/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer cE4v8Zf3k5bPV6g6haade1D" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer cE4v8Zf3k5bPV6g6haade1D",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List employee bank accounts
requires authentication employee-bank-account index
List all bank accounts for an employee
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/19/bank-account" \
--header "Authorization: Bearer Dkcg8V63Z1a4h6E5Pdbfaev" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/19/bank-account"
);
const headers = {
"Authorization": "Bearer Dkcg8V63Z1a4h6E5Pdbfaev",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create employee bank account
requires authentication employee-bank-account store
Add a bank account to an employee
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employees/5/bank-account" \
--header "Authorization: Bearer g8f5ZvEbVe4PhaDc361ad6k" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"bank_id\": \"nemo\",
\"agency\": \"kqhthoqmxfyenixggfkjmi\",
\"account\": \"rvszwfqfituhnhersuiiqrs\",
\"account_type\": \"corrente\",
\"pix_key\": \"fvazxoqlbdciqmdthm\",
\"favorite\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/5/bank-account"
);
const headers = {
"Authorization": "Bearer g8f5ZvEbVe4PhaDc361ad6k",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"bank_id": "nemo",
"agency": "kqhthoqmxfyenixggfkjmi",
"account": "rvszwfqfituhnhersuiiqrs",
"account_type": "corrente",
"pix_key": "fvazxoqlbdciqmdthm",
"favorite": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update employee bank account
requires authentication employee-bank-account update
Update a bank account for an employee
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/employees/2/bank-account/019556e7-2e9f-777c-a177-30bbf0646c33" \
--header "Authorization: Bearer vbge6ZP8Ecd6akh4a5fDV31" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"bank_id\": \"qui\",
\"agency\": \"ofodtqu\",
\"account\": \"lieiiuezkkkpixunfjvhh\",
\"account_type\": \"corrente\",
\"pix_key\": \"bizlbqbpdg\",
\"favorite\": false
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/2/bank-account/019556e7-2e9f-777c-a177-30bbf0646c33"
);
const headers = {
"Authorization": "Bearer vbge6ZP8Ecd6akh4a5fDV31",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"bank_id": "qui",
"agency": "ofodtqu",
"account": "lieiiuezkkkpixunfjvhh",
"account_type": "corrente",
"pix_key": "bizlbqbpdg",
"favorite": false
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete employee bank account
requires authentication employee-bank-account delete
Delete a bank account from an employee
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/employees/019556e7-2e9f-777c-a177-30bbf0646c32/bank-account/019556e7-2e9f-777c-a177-30bbf0646c33" \
--header "Authorization: Bearer Df58gdaVEba1cP643v6ekhZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/019556e7-2e9f-777c-a177-30bbf0646c32/bank-account/019556e7-2e9f-777c-a177-30bbf0646c33"
);
const headers = {
"Authorization": "Bearer Df58gdaVEba1cP643v6ekhZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List employee EPI deliveries
requires authentication employee-epi index
List EPI deliveries for an employee
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/16/epi-deliveries" \
--header "Authorization: Bearer c6f1vbdDE64haZgP5Ve3a8k" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"q\": \"id\",
\"status\": \"expiring\",
\"epi_type_id\": \"sunt\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/16/epi-deliveries"
);
const headers = {
"Authorization": "Bearer c6f1vbdDE64haZgP5Ve3a8k",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"q": "id",
"status": "expiring",
"epi_type_id": "sunt"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Pending EPI renewals count
requires authentication employee-epi index
Count of pending EPI renewals for an employee
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/rerum/epi-deliveries/pending-renewals-count" \
--header "Authorization: Bearer 5cZa8gvVhPk3Dd6eabf1E64" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/rerum/epi-deliveries/pending-renewals-count"
);
const headers = {
"Authorization": "Bearer 5cZa8gvVhPk3Dd6eabf1E64",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show employee EPI delivery
requires authentication employee-epi show
Show an EPI delivery for an employee
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/7/epi-deliveries/et" \
--header "Authorization: Bearer Dh6k63Za8dV1a4Ecvfe5bgP" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/7/epi-deliveries/et"
);
const headers = {
"Authorization": "Bearer Dh6k63Za8dV1a4Ecvfe5bgP",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create employee EPI delivery
requires authentication employee-epi store
Register an EPI delivery for an employee
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employees/15/epi-deliveries" \
--header "Authorization: Bearer gVEf1aPd3aD458ve6hbkcZ6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"epi_type_id\": \"db1abe0c-184b-30a1-9d47-4b0388d4ae47\",
\"delivery_date\": \"2024-01-01\",
\"quantity\": 1,
\"condition\": \"Example Condition\",
\"delivered_by_employee_id\": \"ede5ec0d-c302-4529-a1b7-72d23ddfece3\",
\"stock_id\": \"cdee2984-895a-3f2d-9897-c5b5368eeb88\",
\"confirm_insufficient_stock\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/15/epi-deliveries"
);
const headers = {
"Authorization": "Bearer gVEf1aPd3aD458ve6hbkcZ6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"epi_type_id": "db1abe0c-184b-30a1-9d47-4b0388d4ae47",
"delivery_date": "2024-01-01",
"quantity": 1,
"condition": "Example Condition",
"delivered_by_employee_id": "ede5ec0d-c302-4529-a1b7-72d23ddfece3",
"stock_id": "cdee2984-895a-3f2d-9897-c5b5368eeb88",
"confirm_insufficient_stock": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create employee initial EPI kit
requires authentication employee-epi kit
Register multiple EPI deliveries as initial kit
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employees/qui/epi-deliveries/kit" \
--header "Authorization: Bearer D4k85eZ1v3EfcbPdhV66aag" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"delivery_date\": \"2024-01-01\",
\"is_kit_initial\": true,
\"show_epi_receipt_text\": true,
\"delivered_by_employee_id\": \"6255722f-a343-42e9-8d97-1f4ec9d8c99d\",
\"stock_id\": \"b9f07038-e239-3555-82ad-1ed6dce5f653\",
\"confirm_insufficient_stock\": true,
\"items\": [
{
\"epi_type_id\": \"c7b95825-1be9-3d50-bed5-0694bfb03ae5\",
\"quantity\": 1,
\"condition\": \"Example Items * condition\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/qui/epi-deliveries/kit"
);
const headers = {
"Authorization": "Bearer D4k85eZ1v3EfcbPdhV66aag",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"delivery_date": "2024-01-01",
"is_kit_initial": true,
"show_epi_receipt_text": true,
"delivered_by_employee_id": "6255722f-a343-42e9-8d97-1f4ec9d8c99d",
"stock_id": "b9f07038-e239-3555-82ad-1ed6dce5f653",
"confirm_insufficient_stock": true,
"items": [
{
"epi_type_id": "c7b95825-1be9-3d50-bed5-0694bfb03ae5",
"quantity": 1,
"condition": "Example Items * condition"
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Promote EPI delivery to kit
requires authentication employee-epi kit
Turn a standalone EPI delivery into a single-item kit so it can generate the acknowledgement term. Idempotent: a delivery already belonging to a kit is returned unchanged.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employees/sint/epi-deliveries/commodi/promote-to-kit" \
--header "Authorization: Bearer hZ4ebaDv8d6c3V6f1PE5gka" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/sint/epi-deliveries/commodi/promote-to-kit"
);
const headers = {
"Authorization": "Bearer hZ4ebaDv8d6c3V6f1PE5gka",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update employee EPI delivery
requires authentication employee-epi update
Update an EPI delivery for an employee
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/employees/3/epi-deliveries/aut" \
--header "Authorization: Bearer bka136avZ45eDVhEPc8fdg6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"epi_type_id\": \"c20df7ac-9223-372f-8f90-8402988545b8\",
\"delivery_date\": \"2024-01-01\",
\"quantity\": 1,
\"condition\": \"Example Condition\",
\"delivered_by_employee_id\": \"ca810a8c-50a2-4587-b452-752379cbe668\",
\"stock_id\": \"40e67527-c848-3f58-a4e1-4754224f5f18\",
\"confirm_insufficient_stock\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/3/epi-deliveries/aut"
);
const headers = {
"Authorization": "Bearer bka136avZ45eDVhEPc8fdg6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"epi_type_id": "c20df7ac-9223-372f-8f90-8402988545b8",
"delivery_date": "2024-01-01",
"quantity": 1,
"condition": "Example Condition",
"delivered_by_employee_id": "ca810a8c-50a2-4587-b452-752379cbe668",
"stock_id": "40e67527-c848-3f58-a4e1-4754224f5f18",
"confirm_insufficient_stock": true
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete employee EPI delivery
requires authentication employee-epi delete
Delete an EPI delivery from an employee
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/employees/qui/epi-deliveries/facilis" \
--header "Authorization: Bearer b6VcPea5EhafZgd43D6vk81" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/qui/epi-deliveries/facilis"
);
const headers = {
"Authorization": "Bearer b6VcPea5EhafZgd43D6vk81",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List employee EPI terms
requires authentication employee-epi index
List initial EPI kit terms for an employee
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/20/epi-terms" \
--header "Authorization: Bearer 8agfVhP14ekc3a6b65dEZDv" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"sort_by\": \"created_at\",
\"sort_desc\": false,
\"page\": 60,
\"per_page\": 15,
\"q\": \"eos\",
\"employee_id\": \"velit\",
\"has_term\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/20/epi-terms"
);
const headers = {
"Authorization": "Bearer 8agfVhP14ekc3a6b65dEZDv",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"sort_by": "created_at",
"sort_desc": false,
"page": 60,
"per_page": 15,
"q": "eos",
"employee_id": "velit",
"has_term": true
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Upload signed EPI term
requires authentication employee-epi update
Upload signed Termo de Ciência for an initial kit
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/employees/aspernatur/epi-terms/95628710-ad5d-3887-aa59-10a4c7ded213/upload" \
--header "Authorization: Bearer 1aEbv8eP3ZgchfkdVD4566a" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"file\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example File path\",
\"name\": \"Example Name\",
\"extension\": \"Example File extension\",
\"size\": \"Example File size\",
\"mime_type\": \"Example File mime type\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/aspernatur/epi-terms/95628710-ad5d-3887-aa59-10a4c7ded213/upload"
);
const headers = {
"Authorization": "Bearer 1aEbv8eP3ZgchfkdVD4566a",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"file": {
"0": "example1",
"1": "example2",
"path": "Example File path",
"name": "Example Name",
"extension": "Example File extension",
"size": "Example File size",
"mime_type": "Example File mime type"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Download signed EPI term
requires authentication employee-epi show
Get temporary download URL for signed term
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/voluptatem/epi-terms/f2e9ca31-aa58-340b-8560-8a84b9e9d00b/document" \
--header "Authorization: Bearer h54vaV31agEk6cd86fbPDeZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/voluptatem/epi-terms/f2e9ca31-aa58-340b-8560-8a84b9e9d00b/document"
);
const headers = {
"Authorization": "Bearer h54vaV31agEk6cd86fbPDeZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Endpoints
GET api/up
No specific permission required
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/up" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/up"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "API is running"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Files
Endpoints for files
Delete file
requires authentication No specific permission required
Delete a file
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/files/c56695d3-117c-33bd-a64b-b08f98927bdc" \
--header "Authorization: Bearer D5eabkPZ6h4vVd6Ef381gac" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/files/c56695d3-117c-33bd-a64b-b08f98927bdc"
);
const headers = {
"Authorization": "Bearer D5eabkPZ6h4vVd6Ef381gac",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get file info
requires authentication No specific permission required
Get file information
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/files/793f1c07-7de7-3843-8ef7-16c60ce0641f/info" \
--header "Authorization: Bearer 46ehkE83ad5ZDfVgv16Pbca" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/files/793f1c07-7de7-3843-8ef7-16c60ce0641f/info"
);
const headers = {
"Authorization": "Bearer 46ehkE83ad5ZDfVgv16Pbca",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"uuid": "string",
"name": "string",
"size": "integer",
"type": "string",
"extension": "string",
"path": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate download URL
requires authentication No specific permission required
Generate a signed URL for downloading a file
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/files/78dc4913-8101-3f5d-ae7c-24b6d94cd5a6/download" \
--header "Authorization: Bearer vDgk1cdE463ea8hVfPabZ56" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/files/78dc4913-8101-3f5d-ae7c-24b6d94cd5a6/download"
);
const headers = {
"Authorization": "Bearer vDgk1cdE463ea8hVfPabZ56",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"url": "string",
"filename": "string",
"size": "integer",
"type": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate upload URL
requires authentication No specific permission required
Generate a signed URL for uploading a file
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/files/generate-upload-url" \
--header "Authorization: Bearer PaVZbck684f5D6gdh3vEa1e" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"path\": \"Example Path\",
\"mimetype\": \"Example Mimetype\",
\"public\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/files/generate-upload-url"
);
const headers = {
"Authorization": "Bearer PaVZbck684f5D6gdh3vEa1e",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"path": "Example Path",
"mimetype": "Example Mimetype",
"public": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"url": "string",
"path": "string",
"headers": "array"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate bulk upload URL
requires authentication No specific permission required
Generate signed URLs for uploading multiple files
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/files/generate-bulk-upload-url" \
--header "Authorization: Bearer 6ead1VfDZ4E3a5cbkgvh8P6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"files\": [
{
\"path\": \"Example Files * path\",
\"mimetype\": \"Example Files * mimetype\",
\"public\": true
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/files/generate-bulk-upload-url"
);
const headers = {
"Authorization": "Bearer 6ead1VfDZ4E3a5cbkgvh8P6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"files": [
{
"path": "Example Files * path",
"mimetype": "Example Files * mimetype",
"public": true
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
[
{
"url": "string",
"path": "string",
"headers": "array"
}
]
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Fiscal Documents
Endpoints para gerenciar notas fiscais (arquivos XML/PDF e vínculo com obras).
List fiscal documents
requires authentication fiscal-documents index
Lista notas fiscais com filtros por busca, fornecedor, obra e período.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/fiscal-documents" \
--header "Authorization: Bearer E4af8Zdbae1D36VP5vhg6ck" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"q\": \"expedita\",
\"document_type\": \"nfe\",
\"supplier_id\": \"delectus\",
\"work_id\": \"a\",
\"products_status\": \"pending\",
\"financial_status\": \"pending\",
\"start_date\": \"2026-11-26T13:17:39\",
\"end_date\": \"2094-06-19\",
\"per_page\": 2,
\"cost_centers\": [
\"eum\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents"
);
const headers = {
"Authorization": "Bearer E4af8Zdbae1D36VP5vhg6ck",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"q": "expedita",
"document_type": "nfe",
"supplier_id": "delectus",
"work_id": "a",
"products_status": "pending",
"financial_status": "pending",
"start_date": "2026-11-26T13:17:39",
"end_date": "2094-06-19",
"per_page": 2,
"cost_centers": [
"eum"
]
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "25842c57-e0cc-3521-8411-ddf498da550d",
"document_type": "nfe",
"document_type_label": "NF-e",
"service_description": null,
"nfe_access_key": "50287234836114672584722252894003267903845535",
"nfe_number": "950604",
"nfe_series": "41",
"issue_date": "2011-08-12T03:00:00.000000Z",
"total_value": "6240.78",
"emit": {
"cnpj": "82347503474606",
"name": "Kertzmann, Brekke and Dickens"
},
"dest": {
"document": "49477278050513",
"name": "Rippin, Wilderman and Krajcik"
},
"supplier": {
"id": "a351a0d3-fa87-4217-9f97-2a72c6424c40",
"name": "Dr. Sérgio Queirós",
"document": "09.492.635/0001-28"
},
"financial_status": "pending",
"products_imported_at": null,
"created_at": null
},
{
"id": "21e28d7c-af75-3ba0-afaa-3632cf5383c5",
"document_type": "nfe",
"document_type_label": "NF-e",
"service_description": null,
"nfe_access_key": "61251792453563713398007796238360374790014217",
"nfe_number": "559546",
"nfe_series": "39",
"issue_date": "2005-03-12T03:00:00.000000Z",
"total_value": "9094.78",
"emit": {
"cnpj": "89070338256456",
"name": "Torphy LLC"
},
"dest": {
"document": "97041603169024",
"name": "Botsford-Gibson"
},
"supplier": {
"id": "a351a0d3-fede-4dc6-8ff7-b156fd1c20c2",
"name": "Angélica Beltrão Santana",
"document": "01.048.962/0001-83"
},
"financial_status": "pending",
"products_imported_at": null,
"created_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 15,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create fiscal document
requires authentication fiscal-documents store
Registra uma NFe a partir do XML já enviado ao S3 e o vincula às obras informadas.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents" \
--header "Authorization: Bearer bE6gaDPV8k4hZ6e15fd3acv" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"s3_file_path\": \"dicta\",
\"original_filename\": \".xml$\\/i\",
\"work_ids\": [
\"nobis\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents"
);
const headers = {
"Authorization": "Bearer bE6gaDPV8k4hZ6e15fd3acv",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"s3_file_path": "dicta",
"original_filename": ".xml$\/i",
"work_ids": [
"nobis"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "0e0ffd8d-c411-3996-96b3-b93d03155d02",
"document_type": "nfe",
"document_type_label": "NF-e",
"service_description": null,
"nfe_access_key": "10508266679817240681797291017800633866266438",
"nfe_number": "064933",
"nfe_series": "66",
"issue_date": "2011-07-05T03:00:00.000000Z",
"total_value": "8763.29",
"emit": {
"cnpj": "41017285706868",
"name": "Carter-Ritchie"
},
"dest": {
"document": "46901139238237",
"name": "Marks and Sons"
},
"supplier": {
"id": "a351a0d4-089a-4b75-95ba-a522dd73c358",
"name": "Dr. Christian Mendes Colaço",
"document": "98.773.402/0001-23"
},
"financial_status": "pending",
"products_imported_at": null,
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get fiscal document
requires authentication fiscal-documents show
Detalha uma nota fiscal com arquivos e obras vinculadas.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/fiscal-documents/voluptatibus" \
--header "Authorization: Bearer DP1Zk6e34cVbgaf5Evd8h6a" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/voluptatibus"
);
const headers = {
"Authorization": "Bearer DP1Zk6e34cVbgaf5Evd8h6a",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "8e14653d-540f-33c5-a0fe-bcf0f4fbaa64",
"document_type": "nfe",
"document_type_label": "NF-e",
"service_description": null,
"nfe_access_key": "18049473276901330810161122758647163544011003",
"nfe_number": "041973",
"nfe_series": "68",
"issue_date": "1988-03-12T03:00:00.000000Z",
"total_value": "4728.19",
"emit": {
"cnpj": "64474777492452",
"name": "Kuhic Ltd"
},
"dest": {
"document": "70583757977993",
"name": "Lang, Hermann and Harris"
},
"supplier": {
"id": "a351a0d4-111d-4a14-981a-40eed3f39d28",
"name": "César Reis Furtado",
"document": "17.269.330/0001-80"
},
"financial_status": "pending",
"products_imported_at": null,
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Fiscal document by cost center
requires authentication fiscal-documents show
Distribui a nota por centro de custo. NF-e de produto sai do estoque: o que a vinculação dos itens lançou em cada estoque de obra (quantidade × preço do lote, o mesmo cálculo do custo apropriado do painel), o que foi para o estoque principal e o que ainda não foi integrado. NFS-e sai das parcelas, pelo centro da conta gerada. As linhas somam o total da nota; a diferença vai para other_values, que pode ser negativo quando há desconto. Linhas zeradas são omitidas.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/fiscal-documents/aut/cost-centers" \
--header "Authorization: Bearer EVhkDa43adZev6bf6P51c8g" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/aut/cost-centers"
);
const headers = {
"Authorization": "Bearer EVhkDa43adZev6bf6P51c8g",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"total": "5074.19",
"source": "stock",
"rows": [
{
"kind": "cost_center",
"cost_center": {
"id": "uuid",
"code": "002.001",
"name": "Residencial Vila Nova"
},
"amount": "2100.00",
"share": 41.39
},
{
"kind": "work_without_cost_center",
"work": {
"id": "uuid",
"name": "Reforma Centro"
},
"amount": "474.19",
"share": 9.35
},
{
"kind": "main_stock",
"cost_center": {
"id": "uuid",
"code": "003.001",
"name": "Estoque central"
},
"amount": "1500.00",
"share": 29.56
},
{
"kind": "not_integrated",
"amount": "900.00",
"share": 17.74
},
{
"kind": "other_values",
"amount": "100.00",
"share": 1.97
}
]
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete fiscal document
requires authentication fiscal-documents delete
Exclui definitivamente uma nota fiscal. Não permitido quando a nota já gerou parcelas no financeiro ou já teve produtos importados.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/velit" \
--header "Authorization: Bearer akZvcPE6eb4VD8516fghda3" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/velit"
);
const headers = {
"Authorization": "Bearer akZvcPE6eb4VD8516fghda3",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204, Nota fiscal excluída.):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Attach file
requires authentication fiscal-documents update
Anexa um arquivo (ex.: PDF da NF) já enviado ao S3 à nota fiscal.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/aliquam/files" \
--header "Authorization: Bearer Vf6Zd1hEgec4b65Da3Pvka8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"file\": {
\"path\": \"molestiae\",
\"name\": \"distinctio\",
\"extension\": \"et\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/aliquam/files"
);
const headers = {
"Authorization": "Bearer Vf6Zd1hEgec4b65Da3Pvka8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"file": {
"path": "molestiae",
"name": "distinctio",
"extension": "et"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "c34d4314-2564-39d4-b5d3-120d31fd6331",
"document_type": "nfe",
"document_type_label": "NF-e",
"service_description": null,
"nfe_access_key": "42756555610218196670791530409438998884850696",
"nfe_number": "614780",
"nfe_series": "86",
"issue_date": "2007-10-20T02:00:00.000000Z",
"total_value": "6512.26",
"emit": {
"cnpj": "74657097297712",
"name": "McClure, Stark and Huel"
},
"dest": {
"document": "14112940142829",
"name": "Kris-Braun"
},
"supplier": {
"id": "a351a0d4-1fae-4173-a2eb-71aafc4eebb6",
"name": "Aaron Saito Neto",
"document": "15.439.039/0001-87"
},
"financial_status": "pending",
"products_imported_at": null,
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Detach file
requires authentication fiscal-documents update
Remove definitivamente um anexo da nota fiscal, inclusive o objeto no S3. O XML original da NFe não pode ser removido.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/aspernatur/files/tempore" \
--header "Authorization: Bearer cZ5fe1h83P6bgadEkv46DaV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/aspernatur/files/tempore"
);
const headers = {
"Authorization": "Bearer cZ5fe1h83P6bgadEkv46DaV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "134bfdcc-2643-30ad-8597-94d60ab83bbd",
"document_type": "nfe",
"document_type_label": "NF-e",
"service_description": null,
"nfe_access_key": "03733451341602241965644809474676888258147644",
"nfe_number": "102650",
"nfe_series": "28",
"issue_date": "2000-05-08T03:00:00.000000Z",
"total_value": "6538.84",
"emit": {
"cnpj": "54317438468040",
"name": "Nienow, Cremin and Farrell"
},
"dest": {
"document": "10598873390267",
"name": "O'Connell and Sons"
},
"supplier": {
"id": "a351a0d4-2836-47d0-96e2-81592d8ff16a",
"name": "Eunice D'ávila Vasques",
"document": "36.982.109/0001-19"
},
"financial_status": "pending",
"products_imported_at": null,
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Sync works
requires authentication fiscal-documents update
Sincroniza o vínculo documental da nota fiscal com N obras.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/dolor/works" \
--header "Authorization: Bearer c6d83vaEPVa4bDfZ65gkh1e" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"work_ids\": [
\"numquam\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/dolor/works"
);
const headers = {
"Authorization": "Bearer c6d83vaEPVa4bDfZ65gkh1e",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"work_ids": [
"numquam"
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "7ebbd5d1-c4f6-31a2-9daf-995ee69886e0",
"document_type": "nfe",
"document_type_label": "NF-e",
"service_description": null,
"nfe_access_key": "85169786105174255116930944848303441095883325",
"nfe_number": "133818",
"nfe_series": "39",
"issue_date": "1970-12-03T03:00:00.000000Z",
"total_value": "7959.48",
"emit": {
"cnpj": "37361978027581",
"name": "Schamberger-Jacobson"
},
"dest": {
"document": "57393461058293",
"name": "Brekke, Beer and Hand"
},
"supplier": {
"id": "a351a0d4-3072-4fe1-b256-49feabd92293",
"name": "Edilson Balestero Neto",
"document": "16.403.676/0001-66"
},
"financial_status": "pending",
"products_imported_at": null,
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create installment
requires authentication fiscal-documents update
Lança uma cobrança avulsa na nota fiscal, para o boleto que o fornecedor cobra além das duplicatas do XML. Nasce pendente e sem conta no financeiro; a geração continua sendo pelo import-nfe.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/exercitationem/installments" \
--header "Authorization: Bearer dvg1Vbh6fP4acea35Dk8EZ6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"due_date\": \"2024-01-01\",
\"amount\": 1,
\"number\": \"Example Number\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/fiscal-documents/exercitationem/installments"
);
const headers = {
"Authorization": "Bearer dvg1Vbh6fP4acea35Dk8EZ6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"due_date": "2024-01-01",
"amount": 1,
"number": "Example Number"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "f1f3e915-3b4c-3893-9af6-bbb7c8c71c02",
"document_type": "nfe",
"document_type_label": "NF-e",
"service_description": null,
"nfe_access_key": "08134940718329834591883920684110746467315979",
"nfe_number": "361283",
"nfe_series": "78",
"issue_date": "2021-10-18T03:00:00.000000Z",
"total_value": "6019.54",
"emit": {
"cnpj": "00534172110177",
"name": "Cassin Ltd"
},
"dest": {
"document": "72281042426476",
"name": "Gibson Inc"
},
"supplier": {
"id": "a351a0d4-3927-487c-a958-46d9249978eb",
"name": "Márcio Igor Fonseca Sobrinho",
"document": "05.404.588/0001-62"
},
"financial_status": "pending",
"products_imported_at": null,
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Import
Endpoints for managing NFe imports and product processing.
NFe Imports
Import and process Brazilian electronic invoice (NFe) files.
Create NFe Import
requires authentication imports store
Upload and process a Brazilian NFe (Nota Fiscal Eletrônica) XML file. The file should be uploaded to S3 first, then this endpoint processes it asynchronously.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/imports/nfe/products" \
--header "Authorization: Bearer kcDha1Ve65d4gEfbP38va6Z" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"s3_file_path\": \"imports\\/nfe_12345.xml\",
\"original_filename\": \"nota_fiscal_001.xml\",
\"import_type\": \"nfe\",
\"fiscal_document_id\": \"b4150a73-a175-3605-a187-2fe98eb68a95\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/imports/nfe/products"
);
const headers = {
"Authorization": "Bearer kcDha1Ve65d4gEfbP38va6Z",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"s3_file_path": "imports\/nfe_12345.xml",
"original_filename": "nota_fiscal_001.xml",
"import_type": "nfe",
"fiscal_document_id": "b4150a73-a175-3605-a187-2fe98eb68a95"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201, Import created successfully):
{
"import_id": "9d2f8e4a-1b3c-4d5e-6f7a-8b9c0d1e2f3a",
"status": "pending",
"channel": "import-progress.9d2f8e4a-1b3c-4d5e-6f7a-8b9c0d1e2f3a"
}
Example response (404, File not found in S3):
{
"error": "Arquivo não encontrado no S3"
}
Example response (422, Invalid XML or not a valid NFe):
{
"error": "Arquivo XML inválido ou não é uma NFe"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List Imports
requires authentication imports index
List all NFe imports with filtering and pagination options.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/imports?sort_by=created_at&sort_desc=1&page=1&per_page=15&status=completed&import_type=nfe" \
--header "Authorization: Bearer cZfD1v5k36Pab4dgE8a6ehV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/imports"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"status": "completed",
"import_type": "nfe",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer cZfD1v5k36Pab4dgE8a6ehV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200, Imports retrieved successfully):
{
"data": [
{
"id": "9d2f8e4a-1b3c-4d5e-6f7a-8b9c0d1e2f3a",
"status": "completed",
"import_type": "nfe",
"original_filename": "nota_fiscal_001.xml",
"nfe_number": "123456",
"nfe_date": "2023-12-01",
"total_products": 15,
"processed_products": 15,
"progress_percentage": 100,
"imported_at": "2023-12-01T10:30:00.000Z",
"supplier": {
"name": "Fornecedor Ltda",
"document": "12345678000199"
}
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Import Details
requires authentication imports show
Retrieve detailed information about a specific NFe import, including progress and supplier data.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/imports/porro" \
--header "Authorization: Bearer gf6hae53PE8dD64acvb1kZV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/imports/porro"
);
const headers = {
"Authorization": "Bearer gf6hae53PE8dD64acvb1kZV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200, Import details retrieved successfully):
{
"import_id": "9d2f8e4a-1b3c-4d5e-6f7a-8b9c0d1e2f3a",
"status": "completed",
"import_type": "nfe",
"original_filename": "nota_fiscal_001.xml",
"nfe_number": "123456",
"nfe_date": "2023-12-01",
"total_products": 15,
"processed_products": 10,
"progress_percentage": 66.67,
"auto_linked_count": 4,
"stock_launched_count": 7,
"pending_stock_launch_count": 3,
"imported_by": "João Silva",
"imported_at": "2023-12-01T10:30:00.000Z",
"supplier": {
"id": "supplier-uuid",
"name": "Fornecedor Ltda",
"document": "12345678000199"
},
"fiscal_document": {
"id": "fiscal-document-uuid",
"nfe_number": "123456",
"works": [
{
"id": "work-uuid",
"name": "Hospital Bom Jesus",
"cost_center": {
"id": "cost-center-uuid",
"code": "002.001",
"name": "Hospital Bom Jesus"
}
},
{
"id": "work-uuid-2",
"name": "Reforma Centro",
"cost_center": null
}
]
},
"channel": "import-progress.9d2f8e4a-1b3c-4d5e-6f7a-8b9c0d1e2f3a"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete Import
requires authentication imports delete
Delete an NFe import along with its supplier products and pending link mappings. Only allowed when no imported product has been linked to a system product and the import is not being processed.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/imports/ea" \
--header "Authorization: Bearer kdfD8ZE65hvag61bPe3ca4V" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/imports/ea"
);
const headers = {
"Authorization": "Bearer kdfD8ZE65hvag61bPe3ca4V",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204, Import deleted successfully):
Empty response
Example response (422, Import has linked products or is still processing):
{
"error": "Não é possível excluir uma importação com produtos já vinculados."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Import Products
requires authentication import-products index
List all products from a specific NFe import with filtering and pagination options.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/imports/repellat/products?sort_by=created_at&sort_desc=1&page=1&per_page=15&status=pending&q=Produto+ABC" \
--header "Authorization: Bearer b6aag4dch3k5DEeP8v6VZ1f" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/imports/repellat/products"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"status": "pending",
"q": "Produto ABC",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer b6aag4dch3k5DEeP8v6VZ1f",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200, Products retrieved successfully):
{
"import": {
"id": "9d2f8e4a-1b3c-4d5e-6f7a-8b9c0d1e2f3a",
"total_products": 15,
"processed_products": 10,
"progress_percentage": 66.67
},
"products": {
"data": [
{
"id": "product-uuid",
"supplier_product_code": "ABC123",
"ean_code": "7891234567890",
"name": "Nome do Produto",
"unit": "UN",
"quantity": 10,
"unit_price": 15.5,
"total_price": 155,
"is_processed": false,
"system_product": null,
"linked_at": null,
"linked_by": null,
"has_stock_movement": false
}
]
},
"pagination": {
"current_page": 1,
"per_page": 15,
"total": 15,
"last_page": 1
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List Import Stock Distributions
requires authentication import-products index
Return, per imported product, how the purchased quantity was distributed across stocks (works and main). Aggregated from stock movements generated by the import.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/imports/et/distributions" \
--header "Authorization: Bearer 5bhDeVa8vE1f66dga4c3PkZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/imports/et/distributions"
);
const headers = {
"Authorization": "Bearer 5bhDeVa8vE1f66dga4c3PkZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200, Distribution breakdown per product):
{
"data": [
{
"product": {
"id": "product-uuid",
"name": "Cano PVC XPTO"
},
"total": 50,
"by_stock": [
{
"stock": {
"id": "stock-uuid-a",
"name": "Obra A",
"is_main": false
},
"quantity": 10
},
{
"stock": {
"id": "stock-uuid-b",
"name": "Obra B",
"is_main": false
},
"quantity": 30
},
{
"stock": {
"id": "main-uuid",
"name": "Principal",
"is_main": true
},
"quantity": 10
}
]
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Link Products
requires authentication import-products link
Inicia, de forma assíncrona, a vinculação de produtos do fornecedor a produtos do sistema ou criação de novos itens no estoque. Retorna 202 com o canal para acompanhar o progresso.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/imports/natus/products/link" \
--header "Authorization: Bearer V51h6P63g8bfa4vkEadZcDe" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"mappings\": [
{
\"distributions\": [
{
\"stock_id\": \"Example Mappings * distributions * stock id\",
\"quantity\": 1
}
]
}
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/imports/natus/products/link"
);
const headers = {
"Authorization": "Bearer V51h6P63g8bfa4vkEadZcDe",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"mappings": [
{
"distributions": [
{
"stock_id": "Example Mappings * distributions * stock id",
"quantity": 1
}
]
}
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (202, Linking accepted and started asynchronously):
{
"message": "Vinculação de produtos iniciada com sucesso",
"total_mappings": 2,
"channel": "imports.{import-uuid}"
}
Example response (422, Error linking products):
{
"error": "Erro ao vincular produtos: Product not found"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Locations
Endpoints for states and cities
List states
requires authentication No specific permission required
List all states paginated
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/locations/states" \
--header "Authorization: Bearer 3P6cD16fa8adZbg4ehEvVk5" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"sort_by\": \"numquam\",
\"sort_desc\": true,
\"page\": 47,
\"per_page\": 14
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/locations/states"
);
const headers = {
"Authorization": "Bearer 3P6cD16fa8adZbg4ehEvVk5",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"sort_by": "numquam",
"sort_desc": true,
"page": 47,
"per_page": 14
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": null,
"name": "maxime ratione",
"abbreviation": "YB"
},
{
"id": null,
"name": "ut magni",
"abbreviation": "ZT"
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 30,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List cities by state
requires authentication No specific permission required
List all cities for a given state
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/locations/states/019556e7-2e9f-777c-a177-30bbf0646c32/cities" \
--header "Authorization: Bearer 6Eh3P1aD6c8Vfbgav54eZkd" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/locations/states/019556e7-2e9f-777c-a177-30bbf0646c32/cities"
);
const headers = {
"Authorization": "Bearer 6Eh3P1aD6c8Vfbgav54eZkd",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": null,
"name": "Kiehnport"
},
{
"id": null,
"name": "Harmonyview"
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Notifications
Endpoints for user notifications
List notifications
requires authentication No specific permission required
List user notifications
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/notifications?sort_by=created_at&sort_desc=1&page=1&per_page=15&module=CashFlow&type=success&priority=10&unread_only=1&read_status=unread&date_start=2024-01-01&date_end=2024-12-31&q=erro+faturamento" \
--header "Authorization: Bearer 6fekaEPh3Dd8V1ab65vc4Zg" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/notifications"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"module": "CashFlow",
"type": "success",
"priority": "10",
"unread_only": "1",
"read_status": "unread",
"date_start": "2024-01-01",
"date_end": "2024-12-31",
"q": "erro faturamento",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 6fekaEPh3Dd8V1ab65vc4Zg",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Mark notifications as read
requires authentication No specific permission required
Mark one or many notifications as read
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/notifications/mark-as-read" \
--header "Authorization: Bearer 6bac5PVf1dveZk43E6aDhg8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"notifications\": [
\"Example Notifications *\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/notifications/mark-as-read"
);
const headers = {
"Authorization": "Bearer 6bac5PVf1dveZk43E6aDhg8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"notifications": [
"Example Notifications *"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Mark notifications as unread
requires authentication No specific permission required
Mark one or many notifications as unread
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/notifications/mark-as-unread" \
--header "Authorization: Bearer 15k6he86ZdaPvgfVaDb3c4E" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"notifications\": [
\"Example Notifications *\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/notifications/mark-as-unread"
);
const headers = {
"Authorization": "Bearer 15k6he86ZdaPvgfVaDb3c4E",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"notifications": [
"Example Notifications *"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Mark all notifications as read
requires authentication No specific permission required
Mark all user notifications as read
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/notifications/mark-all-as-read" \
--header "Authorization: Bearer g8k61ca6bf5a3evVPZDdEh4" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/notifications/mark-all-as-read"
);
const headers = {
"Authorization": "Bearer g8k61ca6bf5a3evVPZDdEh4",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Unread notifications count
requires authentication No specific permission required
Count of unread notifications for the user
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/notifications/unread-count" \
--header "Authorization: Bearer a5gkdvZDb643Pfc86EV1hae" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/notifications/unread-count"
);
const headers = {
"Authorization": "Bearer a5gkdvZDb643Pfc86EV1hae",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Payment Receipts
Endpoints for payment receipts
List payment receipts
requires authentication payment-receipt index
List all payment receipts with filters
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payment-receipts?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Jo%C3%A3o+Silva&employee_id=a01edd80-bf3e-40f7-8613-ccb4be5831b3&receiver_type=employee&start_date=2025-01-01&end_date=2025-12-31&min_amount=100&max_amount=1000&payment_method=PIX&city=S%C3%A3o+Paulo&search=quidem&document=sit&work_id=a01edd80-bf3e-40f7-8613-ccb4be5831b3&cost_center_id=62e1e899-b8c5-3eb5-bcaf-5c34cbf585aa&bank_account_id=a01edd80-bf3e-40f7-8613-ccb4be5831b3" \
--header "Authorization: Bearer c65eZPfk3V8vbghd61a4DEa" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payment-receipts"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "João Silva",
"employee_id": "a01edd80-bf3e-40f7-8613-ccb4be5831b3",
"receiver_type": "employee",
"start_date": "2025-01-01",
"end_date": "2025-12-31",
"min_amount": "100",
"max_amount": "1000",
"payment_method": "PIX",
"city": "São Paulo",
"search": "quidem",
"document": "sit",
"work_id": "a01edd80-bf3e-40f7-8613-ccb4be5831b3",
"cost_center_id": "62e1e899-b8c5-3eb5-bcaf-5c34cbf585aa",
"bank_account_id": "a01edd80-bf3e-40f7-8613-ccb4be5831b3",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer c65eZPfk3V8vbghd61a4DEa",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "fa1ae65e-9f5a-3d95-b2a2-1bcb0c92a077",
"receipt_number": "REC-1587",
"receiver_type": "custom",
"receiver": {
"id": null,
"type": null,
"label": null,
"name": "Mckenzie Rempel V",
"document": "029.797.656-64"
},
"payment": {
"amount": 7086.13,
"amount_in_words": "Valor por extenso de teste",
"method": "cash",
"description": "Voluptatem praesentium fugiat vitae assumenda adipisci."
},
"issuer": {
"name": "Haley-Klein",
"document": "96.414.321/6116-59"
},
"issue": {
"date": "2026-11-11",
"city": "Wernerburgh",
"state": "RS"
},
"created_by": {
"id": "a351a0d4-6ad0-4736-9999-64a133e92c82",
"name": "Gardner Senger"
},
"created_at": null,
"updated_at": null
},
{
"id": "79aafdcf-dae9-33cf-9a91-df55767cd295",
"receipt_number": "REC-4069",
"receiver_type": "custom",
"receiver": {
"id": null,
"type": null,
"label": null,
"name": "Cristian Hettinger",
"document": "554.518.195-79"
},
"payment": {
"amount": 4684.91,
"amount_in_words": "Valor por extenso de teste",
"method": "pix",
"description": "Eos ipsam nam dolore enim delectus nemo."
},
"issuer": {
"name": "Rippin, Kerluke and Hills",
"document": "09.604.363/1551-62"
},
"issue": {
"date": "2026-11-19",
"city": "West Alfordmouth",
"state": "GO"
},
"created_by": {
"id": "a351a0d4-6e08-4be4-adbc-09aa5fa46709",
"name": "Harry Armstrong"
},
"created_at": null,
"updated_at": null
}
],
"pagination": {
"total": 2,
"count": 2,
"per_page": 10,
"current_page": 1,
"total_pages": 1,
"has_more_pages": false
},
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Export payment receipts to Excel
requires authentication payment-receipt export
Dispatches async Excel generation using the same filters as the listing. Frontend is notified via Pusher when ready.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payment-receipts/excel?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Jo%C3%A3o+Silva&employee_id=a01edd80-bf3e-40f7-8613-ccb4be5831b3&receiver_type=employee&start_date=2025-01-01&end_date=2025-12-31&min_amount=100&max_amount=1000&payment_method=PIX&city=S%C3%A3o+Paulo&search=accusamus&document=quia&work_id=a01edd80-bf3e-40f7-8613-ccb4be5831b3&cost_center_id=df087826-649e-37fd-804e-7531566b93f1&bank_account_id=a01edd80-bf3e-40f7-8613-ccb4be5831b3" \
--header "Authorization: Bearer 6Pdb1kDZa58he6VEc4fv3ag" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/excel"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "João Silva",
"employee_id": "a01edd80-bf3e-40f7-8613-ccb4be5831b3",
"receiver_type": "employee",
"start_date": "2025-01-01",
"end_date": "2025-12-31",
"min_amount": "100",
"max_amount": "1000",
"payment_method": "PIX",
"city": "São Paulo",
"search": "accusamus",
"document": "quia",
"work_id": "a01edd80-bf3e-40f7-8613-ccb4be5831b3",
"cost_center_id": "df087826-649e-37fd-804e-7531566b93f1",
"bank_account_id": "a01edd80-bf3e-40f7-8613-ccb4be5831b3",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 6Pdb1kDZa58he6VEc4fv3ag",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (202):
{
"message": "string",
"channel": "string",
"event": "string"
}
Example response (422):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show receipt cash flow config
requires authentication payment-receipt cash-flow-config index
Lista cada forma de pagamento e se ela gera lancamento automatico no fluxo de caixa
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payment-receipts/cash-flow-config" \
--header "Authorization: Bearer b8Pa6v1EhgZc35Dk6aVe4df" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/cash-flow-config"
);
const headers = {
"Authorization": "Bearer b8Pa6v1EhgZc35Dk6aVe4df",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update receipt cash flow config
requires authentication payment-receipt cash-flow-config update
Define, por forma de pagamento, se o recibo gera lancamento automatico no fluxo de caixa
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/cash-flow-config" \
--header "Authorization: Bearer DVk6aha46gbdv83cEefZP51" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"methods\": [
{
\"method\": \"pix\",
\"eligible\": false
}
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/cash-flow-config"
);
const headers = {
"Authorization": "Bearer DVk6aha46gbdv83cEefZP51",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"methods": [
{
"method": "pix",
"eligible": false
}
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show payment receipt
requires authentication payment-receipt show
Show a payment receipt
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payment-receipts/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer 658a4hce1f3gPEbdvVDa6kZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer 658a4hce1f3gPEbdvVDa6kZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "cece07b8-5152-3a9b-b318-6bd5983272d7",
"receipt_number": "REC-4765",
"receiver_type": "custom",
"receiver": {
"id": null,
"type": null,
"label": null,
"name": "Rhoda Lakin",
"document": "694.631.523-07"
},
"payment": {
"amount": 916.46,
"amount_in_words": "Valor por extenso de teste",
"method": "cash",
"description": "Facere nulla suscipit quibusdam dolore blanditiis eum quam."
},
"issuer": {
"name": "Simonis, Fisher and Eichmann",
"document": "05.760.076/9471-79"
},
"issue": {
"date": "2026-11-09",
"city": "West Ignacio",
"state": "PR"
},
"created_by": {
"id": "a351a0d4-81ab-4100-81b3-288bd02cf39d",
"name": "Ebony Padberg Jr."
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create payment receipt
requires authentication payment-receipt store
Create a new payment receipt
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/payment-receipts" \
--header "Authorization: Bearer P8heVZ634cfa6vgkd1b5DaE" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"receiver_type\": \"Example Receiver type\",
\"receiver_id\": \"Example Receiver id\",
\"receiver_name\": \"Example Name\",
\"receiver_document\": \"Example Receiver document\",
\"amount\": 1,
\"amount_in_words\": \"Example Amount in words\",
\"payment_method\": \"Example Payment method\",
\"description\": \"Example Description\",
\"issuer_name\": \"Example Name\",
\"issuer_document\": \"Example Issuer document\",
\"issue_date\": \"2024-01-01\",
\"city\": \"Example City\",
\"state\": \"Example State\",
\"work_id\": \"ac4d1434-f750-3818-8d27-24c5e78352d8\",
\"cost_center_id\": \"b195e346-030c-3337-8a99-4b021b01d755\",
\"bank_account_id\": \"27e9f805-f508-3987-9cf9-51efd1632787\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payment-receipts"
);
const headers = {
"Authorization": "Bearer P8heVZ634cfa6vgkd1b5DaE",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"receiver_type": "Example Receiver type",
"receiver_id": "Example Receiver id",
"receiver_name": "Example Name",
"receiver_document": "Example Receiver document",
"amount": 1,
"amount_in_words": "Example Amount in words",
"payment_method": "Example Payment method",
"description": "Example Description",
"issuer_name": "Example Name",
"issuer_document": "Example Issuer document",
"issue_date": "2024-01-01",
"city": "Example City",
"state": "Example State",
"work_id": "ac4d1434-f750-3818-8d27-24c5e78352d8",
"cost_center_id": "b195e346-030c-3337-8a99-4b021b01d755",
"bank_account_id": "27e9f805-f508-3987-9cf9-51efd1632787"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update payment receipt
requires authentication payment-receipt update
Update a payment receipt
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer aDZc6hP6feb385gkdavE14V" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"receiver_type\": \"Example Receiver type\",
\"receiver_id\": \"Example Receiver id\",
\"receiver_name\": \"Example Name\",
\"receiver_document\": \"Example Receiver document\",
\"amount\": 1,
\"amount_in_words\": \"Example Amount in words\",
\"payment_method\": \"Example Payment method\",
\"description\": \"Example Description\",
\"issuer_name\": \"Example Name\",
\"issuer_document\": \"Example Issuer document\",
\"issue_date\": \"2024-01-01\",
\"city\": \"Example City\",
\"state\": \"Example State\",
\"work_id\": \"454adf24-b806-37b8-99b4-8df4e760abdb\",
\"cost_center_id\": \"2acfd56f-c73d-37d1-ae8d-90b936cec3fc\",
\"bank_account_id\": \"76588b47-e5ad-3a17-87e4-16ca6692576b\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer aDZc6hP6feb385gkdavE14V",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"receiver_type": "Example Receiver type",
"receiver_id": "Example Receiver id",
"receiver_name": "Example Name",
"receiver_document": "Example Receiver document",
"amount": 1,
"amount_in_words": "Example Amount in words",
"payment_method": "Example Payment method",
"description": "Example Description",
"issuer_name": "Example Name",
"issuer_document": "Example Issuer document",
"issue_date": "2024-01-01",
"city": "Example City",
"state": "Example State",
"work_id": "454adf24-b806-37b8-99b4-8df4e760abdb",
"cost_center_id": "2acfd56f-c73d-37d1-ae8d-90b936cec3fc",
"bank_account_id": "76588b47-e5ad-3a17-87e4-16ca6692576b"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete payment receipt
requires authentication payment-receipt delete
Delete a payment receipt
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer VZvh4gke1b53P6adEDa6fc8" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payment-receipts/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer VZvh4gke1b53P6adEDa6fc8",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List employee receipts
requires authentication payment-receipt index
List all payment receipts for a specific employee
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/employees/4/receipts" \
--header "Authorization: Bearer hPa81Decd3EvgV5k6ba4Z6f" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/employees/4/receipts"
);
const headers = {
"Authorization": "Bearer hPa81Decd3EvgV5k6ba4Z6f",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "65dea10a-f155-3fc5-a7ee-daf09aae0441",
"receipt_number": "REC-4150",
"receiver_type": "custom",
"receiver": {
"id": null,
"type": null,
"label": null,
"name": "Prof. Meggie Bechtelar",
"document": "528.937.439-17"
},
"payment": {
"amount": 1458.92,
"amount_in_words": "Valor por extenso de teste",
"method": "pix",
"description": "Sit quod quod libero."
},
"issuer": {
"name": "Nicolas-Zulauf",
"document": "58.707.680/3593-95"
},
"issue": {
"date": "2026-10-30",
"city": "Port Lynn",
"state": "RJ"
},
"created_by": {
"id": "a351a0d4-9c61-4253-9e0a-1d6785431e6a",
"name": "Autumn Greenholt"
},
"created_at": null,
"updated_at": null
},
{
"id": "5314a797-78e2-3ba1-abec-cfc66bfbeaaa",
"receipt_number": "REC-5644",
"receiver_type": "custom",
"receiver": {
"id": null,
"type": null,
"label": null,
"name": "Katherine Grant",
"document": "568.075.922-00"
},
"payment": {
"amount": 231.5,
"amount_in_words": "Valor por extenso de teste",
"method": "check",
"description": "Suscipit reprehenderit minus fugiat omnis iusto."
},
"issuer": {
"name": "Zulauf Inc",
"document": "15.271.852/1726-23"
},
"issue": {
"date": "2026-11-17",
"city": "South Eulalia",
"state": "PE"
},
"created_by": {
"id": "a351a0d4-9ece-4f44-aa9c-42048beb8a70",
"name": "Miss Roberta Weimann"
},
"created_at": null,
"updated_at": null
}
],
"pagination": {
"total": 2,
"count": 2,
"per_page": 10,
"current_page": 1,
"total_pages": 1,
"has_more_pages": false
},
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Payroll Addition Types
Cadastro dos tipos de acréscimo da folha de sexta
List addition types
requires authentication payroll build
Lista ordenada por nome, sem paginação: o cadastro é pequeno e a mesma chamada serve à tela de lista e à lista de escolha do lançamento.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payroll-addition-types?q=omnis&active=1" \
--header "Authorization: Bearer aV6kfP81bhecDgZd6va45E3" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"q\": \"aut\",
\"active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-addition-types"
);
const params = {
"q": "omnis",
"active": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer aV6kfP81bhecDgZd6va45E3",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"q": "aut",
"active": true
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "a351a0d4-adfc-4843-ae22-b569e15bad13",
"name": "nihil sit",
"default_amount": "14.58",
"includes_in_work_cost": true,
"is_active": true,
"in_use": false
},
{
"id": "a351a0d4-aeee-452d-ac38-57f36a75720f",
"name": "rerum rerum",
"default_amount": "53.03",
"includes_in_work_cost": true,
"is_active": true,
"in_use": false
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create addition type
requires authentication payroll build
O nome é único. O valor padrão fica vazio quando o valor varia a cada lançamento.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/payroll-addition-types" \
--header "Authorization: Bearer ghf6ka1d5PVeab3Dc4Z6Ev8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"zfqzdqaxaimpmqb\",
\"default_amount\": 42,
\"includes_in_work_cost\": false,
\"is_active\": false
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-addition-types"
);
const headers = {
"Authorization": "Bearer ghf6ka1d5PVeab3Dc4Z6Ev8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "zfqzdqaxaimpmqb",
"default_amount": 42,
"includes_in_work_cost": false,
"is_active": false
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "a351a0d4-b66d-4504-806c-c17e6c77025e",
"name": "numquam impedit",
"default_amount": "23.26",
"includes_in_work_cost": true,
"is_active": true,
"in_use": false
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show addition type
requires authentication payroll build
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payroll-addition-types/cupiditate" \
--header "Authorization: Bearer hcafab5vgP8Dd4V6Ze61kE3" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-addition-types/cupiditate"
);
const headers = {
"Authorization": "Bearer hcafab5vgP8Dd4V6Ze61kE3",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "a351a0d4-bda8-4679-bda2-d6dc0211e285",
"name": "voluptatem dolorem",
"default_amount": "13.83",
"includes_in_work_cost": true,
"is_active": true,
"in_use": false
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update addition type
requires authentication payroll build
Alterar o cadastro não muda acréscimo já lançado: ele guarda a cópia do nome, do valor e da marcação de custo do momento do lançamento.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/payroll-addition-types/et" \
--header "Authorization: Bearer 34e815VvDE6ZacPbfkhag6d" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"vuxzif\",
\"default_amount\": 35,
\"includes_in_work_cost\": true,
\"is_active\": false
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-addition-types/et"
);
const headers = {
"Authorization": "Bearer 34e815VvDE6ZacPbfkhag6d",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "vuxzif",
"default_amount": 35,
"includes_in_work_cost": true,
"is_active": false
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Tipo de acréscimo atualizado com sucesso."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete addition type
requires authentication payroll build
Só para tipo sem uso. Tipo já lançado em alguma folha é recusado com orientação para inativar.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/payroll-addition-types/harum" \
--header "Authorization: Bearer 1c8DPVvdeE6a5h3ba6fkg4Z" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-addition-types/harum"
);
const headers = {
"Authorization": "Bearer 1c8DPVvdeE6a5h3ba6fkg4Z",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "Tipo de acréscimo excluído com sucesso."
}
Example response (422):
{
"message": "The given data was invalid.",
"errors": {
"name": [
"Este tipo de acréscimo já foi lançado em alguma folha e não pode ser excluído. Inative-o para parar de usá-lo."
]
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Payroll Payments
Baixa da folha: caixa, recibo e dinheiro entregue na obra
Payments of the day
requires authentication payroll pay
Os pagamentos agendados para uma data, agrupados por favorecido, com a chave PIX ao
lado e o total por pessoa. Sem date, traz o dia de hoje.
Os itens já pagos vêm na lista, marcados: quem paga precisa ver o que já saiu para não pagar duas vezes. Folha em rascunho não aparece — pagamento só depois de conferida.
A chave PIX é a gravada no item; não havendo, cai na favorita do cadastro do funcionário ou do fornecedor.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payroll-payments/day?date=2026-11-20" \
--header "Authorization: Bearer PhZ651DgfkeaEV4vd6ba8c3" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"date\": \"2026-11-26\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-payments/day"
);
const params = {
"date": "2026-11-20",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer PhZ651DgfkeaEV4vd6ba8c3",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"date": "2026-11-26"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"date": "2026-11-20",
"totals": {
"grand_total": "530.00",
"pending_total": "350.00",
"items_count": 3,
"pending_count": 2,
"payees_count": 2
},
"payees": [
{
"payee": {
"type": "employee",
"label": "Funcionário",
"id": "uuid",
"name": "José da Silva",
"document": "390.533.447-05"
},
"pix_key": "jose.silva@email.com",
"total": "180.00",
"pending_total": "180.00",
"items_count": 1,
"pending_count": 1,
"items": []
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Settle several payroll items
requires authentication payroll pay
Baixa vários itens de uma vez. Cada item é liquidado na sua própria transação: um item sem saldo na conta não desfaz os que já foram pagos, e a resposta diz quais passaram e quais não.
Com receipt_mode: per_person sai um recibo por favorecido cobrindo todos os itens
dele; com per_payment, um recibo por item.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/payroll-payments/batch" \
--header "Authorization: Bearer 5E3PagZ86ab6fck1evhDdV4" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"bank_account_id\": \"61007eb2-23dc-3dfe-aa0f-bafffb06b4c3\",
\"delivered\": false,
\"delivered_by_name\": \"kahxqggmgdtwtzw\",
\"generate_receipt\": false,
\"receipt_mode\": \"per_payment\",
\"receipt_description\": \"exercitationem\",
\"issuer_name\": \"mqou\",
\"issuer_document\": \"ynes\",
\"city\": \"nvkznilpgmtderhbkkrmwrqjg\",
\"state\": \"du\",
\"items\": [
\"98a2092d-7131-392e-97c9-e0f07975f295\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-payments/batch"
);
const headers = {
"Authorization": "Bearer 5E3PagZ86ab6fck1evhDdV4",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"bank_account_id": "61007eb2-23dc-3dfe-aa0f-bafffb06b4c3",
"delivered": false,
"delivered_by_name": "kahxqggmgdtwtzw",
"generate_receipt": false,
"receipt_mode": "per_payment",
"receipt_description": "exercitationem",
"issuer_name": "mqou",
"issuer_document": "ynes",
"city": "nvkznilpgmtderhbkkrmwrqjg",
"state": "du",
"items": [
"98a2092d-7131-392e-97c9-e0f07975f295"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"settled": [
"uuid-1",
"uuid-2"
],
"failed": [
{
"item": "uuid-3",
"reason": "Saldo insuficiente."
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Settle a payroll item
requires authentication payroll pay
Marca o item como pago e lança no caixa, com a obra e o centro de custo do item, debitando a conta de saída escolhida.
Com delivered, o item fica como entregue em vez de pago — é o dinheiro entregue
na obra, que exige uma conta do tipo caixa e aceita o nome de quem entregou.
O recibo é opcional. Quando pedido, o caixa e o recibo nascem na mesma transação: se um falhar, nenhum dos dois fica gravado.
Sem sessão de caixa aberta, uma é aberta automaticamente — inclusive quando a do dia já foi fechada.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/payroll-payments/laboriosam" \
--header "Authorization: Bearer Va5a6k4ZhceD13EPvbg6fd8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"bank_account_id\": \"99502c02-2c5c-3f59-9d17-9d6cbe8b6a0f\",
\"delivered\": true,
\"delivered_by_name\": \"tmmdyqcwt\",
\"generate_receipt\": false,
\"receipt_mode\": \"per_person\",
\"receipt_description\": \"recusandae\",
\"issuer_name\": \"tysgufivkyxwbxab\",
\"issuer_document\": \"dztmcymkctcb\",
\"city\": \"wbdsmrrevxxmlic\",
\"state\": \"rx\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-payments/laboriosam"
);
const headers = {
"Authorization": "Bearer Va5a6k4ZhceD13EPvbg6fd8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"bank_account_id": "99502c02-2c5c-3f59-9d17-9d6cbe8b6a0f",
"delivered": true,
"delivered_by_name": "tmmdyqcwt",
"generate_receipt": false,
"receipt_mode": "per_person",
"receipt_description": "recusandae",
"issuer_name": "tysgufivkyxwbxab",
"issuer_document": "dztmcymkctcb",
"city": "wbdsmrrevxxmlic",
"state": "rx"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "a351a0d5-28b6-4498-8473-cadc00cf0433",
"payee": {
"type": null,
"label": null,
"id": null,
"name": "Chaya Breitenberg",
"document": "208.126.142-92"
},
"work": null,
"cost_center": null,
"amount": "172.36",
"additions": [],
"total": "172.36",
"work_cost_total": "172.36",
"payment_method": {
"value": "pix",
"label": "PIX"
},
"pix_key": null,
"notes": null,
"scheduled_date": "2026-11-26",
"status": {
"value": "pending",
"label": "Pendente"
},
"is_settled": false,
"paid_at": null,
"paid_by": null,
"delivered_by_name": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Payroll Sheets
Folha de sexta: montar, conferir e reabrir
List payroll sheets
requires authentication payroll index
Folhas por semana, da mais recente para a mais antiga, com os totais por forma de pagamento. A mesma semana pode ter mais de uma folha.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payroll-sheets" \
--header "Authorization: Bearer h6dDc1V8aePZ4E35akv6bgf" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"sort_by\": \"quaerat\",
\"sort_desc\": true,
\"page\": 70,
\"per_page\": 3,
\"q\": \"quo\",
\"status\": \"draft\",
\"period_from\": \"2026-11-26T13:17:39\",
\"period_to\": \"2041-10-09\",
\"payment_date_from\": \"2026-11-26T13:17:39\",
\"payment_date_to\": \"2115-01-24\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets"
);
const headers = {
"Authorization": "Bearer h6dDc1V8aePZ4E35akv6bgf",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"sort_by": "quaerat",
"sort_desc": true,
"page": 70,
"per_page": 3,
"q": "quo",
"status": "draft",
"period_from": "2026-11-26T13:17:39",
"period_to": "2041-10-09",
"payment_date_from": "2026-11-26T13:17:39",
"payment_date_to": "2115-01-24"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "a351a0d4-cba2-4542-b20e-d36dec8f8eb9",
"code": null,
"name": "Escritório",
"period_start": "2026-11-23",
"period_end": "2026-11-29",
"payment_date": "2026-11-27",
"status": {
"value": "draft",
"label": "Rascunho"
},
"items_count": 0,
"grand_total": "0.00",
"by_payment_method": []
},
{
"id": "a351a0d4-cede-43b9-9389-67860c9dd4de",
"code": null,
"name": "Escritório",
"period_start": "2026-11-23",
"period_end": "2026-11-29",
"payment_date": "2026-11-27",
"status": {
"value": "draft",
"label": "Rascunho"
},
"items_count": 0,
"grand_total": "0.00",
"by_payment_method": []
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create payroll sheet
requires authentication payroll build
Nasce em rascunho. O nome distingue folhas da mesma semana, como "Obras" e "Escritório".
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets" \
--header "Authorization: Bearer gbd8E5V3v64cZ6aDePhkfa1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"xkevxhmjiowv\",
\"period_start\": \"2026-11-26T13:17:39\",
\"period_end\": \"2071-08-28\",
\"payment_date\": \"2026-11-26T13:17:39\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets"
);
const headers = {
"Authorization": "Bearer gbd8E5V3v64cZ6aDePhkfa1",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "xkevxhmjiowv",
"period_start": "2026-11-26T13:17:39",
"period_end": "2071-08-28",
"payment_date": "2026-11-26T13:17:39"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "a351a0d4-d6af-439d-8bc7-6f4b1fb222ff",
"code": null,
"name": "Obras",
"period_start": "2026-11-23",
"period_end": "2026-11-29",
"payment_date": "2026-11-27",
"status": {
"value": "draft",
"label": "Rascunho"
},
"accepts_item_changes": true,
"can_reopen": false,
"created_by": {
"id": "a351a0d4-d72c-4e94-8790-d0113a95fad0",
"name": "Mozell Swaniawski"
},
"checked_by": null,
"checked_at": null,
"reopened_by": null,
"reopened_at": null,
"items": [],
"totals": {
"grand_total": "0.00",
"work_cost_total": "0.00",
"items_count": 0,
"by_work": [],
"by_payment_method": []
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show payroll sheet
requires authentication payroll show
Folha com os itens, os acréscimos e os totais por obra e por forma de pagamento, calculados no servidor.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/payroll-sheets/suscipit" \
--header "Authorization: Bearer Z36aP4V6vcegf81Edb5Dkha" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/suscipit"
);
const headers = {
"Authorization": "Bearer Z36aP4V6vcegf81Edb5Dkha",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "a351a0d4-de20-4874-bb3a-563f90a8f95b",
"code": null,
"name": "Escritório",
"period_start": "2026-11-23",
"period_end": "2026-11-29",
"payment_date": "2026-11-27",
"status": {
"value": "draft",
"label": "Rascunho"
},
"accepts_item_changes": true,
"can_reopen": false,
"created_by": {
"id": "a351a0d4-dea6-4f91-9878-227ac5edd1b0",
"name": "Dr. Andy Harber Jr."
},
"checked_by": null,
"checked_at": null,
"reopened_by": null,
"reopened_at": null,
"items": [],
"totals": {
"grand_total": "0.00",
"work_cost_total": "0.00",
"items_count": 0,
"by_work": [],
"by_payment_method": []
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update payroll sheet
requires authentication payroll build
Semana, nome e data de pagamento só mudam em rascunho.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/voluptatum" \
--header "Authorization: Bearer 6VEcZavda3148gPhe5Dk6fb" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"ddgg\",
\"period_start\": \"2026-11-26T13:17:39\",
\"period_end\": \"2098-06-03\",
\"payment_date\": \"2026-11-26T13:17:39\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/voluptatum"
);
const headers = {
"Authorization": "Bearer 6VEcZavda3148gPhe5Dk6fb",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "ddgg",
"period_start": "2026-11-26T13:17:39",
"period_end": "2098-06-03",
"payment_date": "2026-11-26T13:17:39"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Folha atualizada com sucesso."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete payroll sheet
requires authentication payroll build
Só em rascunho. Apagar a folha apaga os itens e os acréscimos dela.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/assumenda" \
--header "Authorization: Bearer EVk6g4d6D1hab8PcZe3fva5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/assumenda"
);
const headers = {
"Authorization": "Bearer EVk6g4d6D1hab8PcZe3fva5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "Folha excluída com sucesso."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add item to payroll sheet
requires authentication payroll build
Lança um pagamento na folha. O favorecido vem do cadastro (payee_type mais payee_id)
ou digitado à mão (receiver_name, sem payee_type) — este último é o dinheiro
entregue na obra para quem não está em cadastro nenhum.
O nome e o documento do favorecido de cadastro são copiados no servidor, para a folha
não mudar quando o cadastro mudar. Sem amount, cai na diária do funcionário. Sem
scheduled_date, herda a data de pagamento da folha.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/voluptas/items" \
--header "Authorization: Bearer 6PEVDfc3eg61adv58bhaZ4k" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"payee_type\": \"employee\",
\"payee_id\": \"372426a1-c510-3330-abc1-ccf873b5a918\",
\"receiver_name\": \"xsmvobj\",
\"receiver_document\": \"jthdbgwusyewkziatne\",
\"work_id\": \"a185704c-1e12-32ee-b372-f5aeebfeff5a\",
\"cost_center_id\": \"recusandae\",
\"amount\": 50,
\"payment_method\": \"cash\",
\"pix_key\": \"zbyyngmgsiqcwwohqusfi\",
\"notes\": \"cjkpzvfqfizrovithctimqcon\",
\"scheduled_date\": \"2026-11-26T13:17:39\",
\"additions\": [
{
\"type_id\": \"612c2e2c-70ed-38a7-b479-069148c52dd8\",
\"amount\": 75
}
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/voluptas/items"
);
const headers = {
"Authorization": "Bearer 6PEVDfc3eg61adv58bhaZ4k",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"payee_type": "employee",
"payee_id": "372426a1-c510-3330-abc1-ccf873b5a918",
"receiver_name": "xsmvobj",
"receiver_document": "jthdbgwusyewkziatne",
"work_id": "a185704c-1e12-32ee-b372-f5aeebfeff5a",
"cost_center_id": "recusandae",
"amount": 50,
"payment_method": "cash",
"pix_key": "zbyyngmgsiqcwwohqusfi",
"notes": "cjkpzvfqfizrovithctimqcon",
"scheduled_date": "2026-11-26T13:17:39",
"additions": [
{
"type_id": "612c2e2c-70ed-38a7-b479-069148c52dd8",
"amount": 75
}
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "a351a0d4-f09d-482c-ba87-ed825ef811d3",
"payee": {
"type": null,
"label": null,
"id": null,
"name": "Reymundo Schroeder",
"document": "954.265.970-91"
},
"work": null,
"cost_center": null,
"amount": "196.93",
"additions": [],
"total": "196.93",
"work_cost_total": "196.93",
"payment_method": {
"value": "pix",
"label": "PIX"
},
"pix_key": null,
"notes": null,
"scheduled_date": "2026-11-26",
"status": {
"value": "pending",
"label": "Pendente"
},
"is_settled": false,
"paid_at": null,
"paid_by": null,
"delivered_by_name": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update payroll sheet item
requires authentication payroll build
Só em folha em rascunho e item ainda não pago. Mandar additions substitui a lista inteira de acréscimos do item.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/rerum/items/voluptas" \
--header "Authorization: Bearer dcahbP35kvga46V8EZD1fe6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"payee_type\": \"supplier\",
\"payee_id\": \"395323fa-2735-31ad-993c-744ecef884ef\",
\"receiver_name\": \"m\",
\"receiver_document\": \"ypgikhkzwzmvkxcuuyvn\",
\"work_id\": \"c4bdd437-d985-3386-a1f1-31b398d81486\",
\"cost_center_id\": \"et\",
\"amount\": 53,
\"payment_method\": \"bank_transfer\",
\"pix_key\": \"kdrrl\",
\"notes\": \"wdukyeqdlkz\",
\"scheduled_date\": \"2026-11-26T13:17:39\",
\"additions\": [
{
\"type_id\": \"e8e080c1-84bc-34e8-a90e-15dde2bf7271\",
\"amount\": 81
}
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/rerum/items/voluptas"
);
const headers = {
"Authorization": "Bearer dcahbP35kvga46V8EZD1fe6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"payee_type": "supplier",
"payee_id": "395323fa-2735-31ad-993c-744ecef884ef",
"receiver_name": "m",
"receiver_document": "ypgikhkzwzmvkxcuuyvn",
"work_id": "c4bdd437-d985-3386-a1f1-31b398d81486",
"cost_center_id": "et",
"amount": 53,
"payment_method": "bank_transfer",
"pix_key": "kdrrl",
"notes": "wdukyeqdlkz",
"scheduled_date": "2026-11-26T13:17:39",
"additions": [
{
"type_id": "e8e080c1-84bc-34e8-a90e-15dde2bf7271",
"amount": 81
}
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "a351a0d4-ff8a-4dbd-9ba4-f77b5a507d79",
"payee": {
"type": null,
"label": null,
"id": null,
"name": "Mr. King Hegmann DDS",
"document": "754.314.494-70"
},
"work": null,
"cost_center": null,
"amount": "359.63",
"additions": [],
"total": "359.63",
"work_cost_total": "359.63",
"payment_method": {
"value": "pix",
"label": "PIX"
},
"pix_key": null,
"notes": null,
"scheduled_date": "2026-11-26",
"status": {
"value": "pending",
"label": "Pendente"
},
"is_settled": false,
"paid_at": null,
"paid_by": null,
"delivered_by_name": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete payroll sheet item
requires authentication payroll build
Só em folha em rascunho e item ainda não pago.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/eius/items/molestias" \
--header "Authorization: Bearer 1aka8Dbfv4gVZE53P6d6ehc" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/eius/items/molestias"
);
const headers = {
"Authorization": "Bearer 1aka8Dbfv4gVZE53P6d6ehc",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "Pagamento removido da folha."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Check payroll sheet
requires authentication payroll check
Confere e trava a folha: a partir daí ela não aceita mais alteração de item. Registra quem conferiu e quando. Folha sem item não é conferível.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/quia/check" \
--header "Authorization: Bearer 8ehE6Vdb1Paa4kfDv3Zg5c6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/quia/check"
);
const headers = {
"Authorization": "Bearer 8ehE6Vdb1Paa4kfDv3Zg5c6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "a351a0d5-0a2b-4f7b-b6b1-f5c3b19deed0",
"code": null,
"name": "Escritório",
"period_start": "2026-11-23",
"period_end": "2026-11-29",
"payment_date": "2026-11-27",
"status": {
"value": "draft",
"label": "Rascunho"
},
"accepts_item_changes": true,
"can_reopen": false,
"created_by": {
"id": "a351a0d5-0a9e-4579-af57-6c1802e10c48",
"name": "Blanca Rohan"
},
"checked_by": null,
"checked_at": null,
"reopened_by": null,
"reopened_at": null,
"items": [],
"totals": {
"grand_total": "0.00",
"work_cost_total": "0.00",
"items_count": 0,
"by_work": [],
"by_payment_method": []
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Reopen payroll sheet
requires authentication payroll check
Volta a folha para rascunho e registra quem reabriu e quando. Recusada quando algum item já foi pago ou entregue.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/ut/reopen" \
--header "Authorization: Bearer P8af53De1V4ZvkagbEdh66c" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/payroll-sheets/ut/reopen"
);
const headers = {
"Authorization": "Bearer P8af53De1V4ZvkagbEdh66c",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "a351a0d5-0fc2-4aac-9f4b-75301b5a2ae2",
"code": null,
"name": "Obras",
"period_start": "2026-11-23",
"period_end": "2026-11-29",
"payment_date": "2026-11-27",
"status": {
"value": "draft",
"label": "Rascunho"
},
"accepts_item_changes": true,
"can_reopen": false,
"created_by": {
"id": "a351a0d5-1029-457d-b395-83d39a50c155",
"name": "Wyatt Miller"
},
"checked_by": null,
"checked_at": null,
"reopened_by": null,
"reopened_at": null,
"items": [],
"totals": {
"grand_total": "0.00",
"work_cost_total": "0.00",
"items_count": 0,
"by_work": [],
"by_payment_method": []
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Permission Groups
Endpoints for permission groups
List ungrouped permissions
requires authentication permission-group index
List all permissions that do not belong to any permission group.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/permission-groups/ungrouped-permissions?q=Permission+name&page=1&per_page=10" \
--header "Authorization: Bearer k6E6dhgbceaf18D45PZVv3a" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/permission-groups/ungrouped-permissions"
);
const params = {
"q": "Permission name",
"page": "1",
"per_page": "10",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer k6E6dhgbceaf18D45PZVv3a",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "d44d4f01-32f1-332d-af7a-b867555b074e",
"name": "laboriosam",
"display_name": "Dolore commodi illo autem similique ea."
},
{
"id": "fd3c8a1b-7b28-3e8d-9348-d2de069637eb",
"name": "consectetur",
"display_name": "Quo impedit et dolores eius alias nobis et."
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List permission groups
requires authentication permission-group index
List all permission groups
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/permission-groups" \
--header "Authorization: Bearer Z6d5bva4aPEkhfDg361c8Ve" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/permission-groups"
);
const headers = {
"Authorization": "Bearer Z6d5bva4aPEkhfDg361c8Ve",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "fa4b30ce-e57d-3793-aa73-69c1f3dc2f41",
"name": "nisi-quae-delectus",
"display_name": "quis commodi maxime",
"created_at": null,
"updated_at": null
},
{
"id": "ae66042a-2f5b-3482-b4f8-660b395b1e28",
"name": "exercitationem-ut-ipsum",
"display_name": "accusantium illo magni",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create permission group
requires authentication permission-group store
Create a new permission group
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/permission-groups" \
--header "Authorization: Bearer v14ak6PchV3Dbde6ag8EZf5" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"display_name\": \"Example Name\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/permission-groups"
);
const headers = {
"Authorization": "Bearer v14ak6PchV3Dbde6ag8EZf5",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"display_name": "Example Name"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update permission group
requires authentication permission-group update
Update a permission group
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1" \
--header "Authorization: Bearer v8643g6bhEZPVecaa51fkdD" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"display_name\": \"Example Name\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1"
);
const headers = {
"Authorization": "Bearer v8643g6bhEZPVecaa51fkdD",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"display_name": "Example Name"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show permission group
requires authentication permission-group show
Show a permission group
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/permission-groups/1" \
--header "Authorization: Bearer 1fk6vZEg5P8dVc3Dab46hea" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1"
);
const headers = {
"Authorization": "Bearer 1fk6vZEg5P8dVc3Dab46hea",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "ef924b53-c517-3971-8539-b9176fa9c874",
"name": "fuga-esse",
"display_name": "qui non ullam",
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete permission group
requires authentication permission-group delete
Delete a permission group
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1" \
--header "Authorization: Bearer 6g3aa6Z8dk4PD5cvbEf1heV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1"
);
const headers = {
"Authorization": "Bearer 6g3aa6Z8dk4PD5cvbEf1heV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Attach permissions to group
requires authentication permission-group permissions-attach
Attach one or more permissions to a permission group. Permissions already in another group are moved to this group.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1/permissions" \
--header "Authorization: Bearer feP8VdZEkb1gD56a4hv3ac6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"permissions\": [
\"44887e83-b870-3af6-804e-088a854373df\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1/permissions"
);
const headers = {
"Authorization": "Bearer feP8VdZEkb1gD56a4hv3ac6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"permissions": [
"44887e83-b870-3af6-804e-088a854373df"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "fab6c870-cb0a-38d8-85c0-e15165529bed",
"name": "tempora-inventore",
"display_name": "natus numquam et",
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Detach permissions from group
requires authentication permission-group permissions-detach
Detach one or more permissions from a permission group. Fails if any permission does not belong to the group.
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1/permissions" \
--header "Authorization: Bearer 8Z14dDk6aEg6ac3veV5Pfbh" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"permissions\": [
\"78fd03e9-9446-327f-a18b-2aef883dbe8f\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/permission-groups/1/permissions"
);
const headers = {
"Authorization": "Bearer 8Z14dDk6aEg6ac3veV5Pfbh",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"permissions": [
"78fd03e9-9446-327f-a18b-2aef883dbe8f"
]
};
fetch(url, {
method: "DELETE",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "8f0d8074-53c1-3ec3-a872-cdf4ddbe8785",
"name": "neque-dolorem",
"display_name": "nostrum aspernatur temporibus",
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Product Brands
Endpoints for product brands
List product brands
requires authentication product-brand index
List all product brands
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-brands?q=Structure" \
--header "Authorization: Bearer 6f6DehcP584gbdaE3VkZva1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-brands"
);
const params = {
"q": "Structure",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 6f6DehcP584gbdaE3VkZva1",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "0abafe27-e147-3c9d-84d7-dfedac892d60",
"name": "Sra. Malu Alves",
"created_at": null,
"updated_at": null
},
{
"id": "84513488-8ed0-36a6-936c-96f4fa8c07fc",
"name": "Dr. Luna Aguiar Gil Sobrinho",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show product brand
requires authentication product-brand show
Show a product brand
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-brands/repellat" \
--header "Authorization: Bearer aP8k6V1h4dcvgaZfDeE53b6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-brands/repellat"
);
const headers = {
"Authorization": "Bearer aP8k6V1h4dcvgaZfDeE53b6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "3460decd-518e-3c7d-ba16-6ba3e3b86515",
"name": "Violeta Gomes Valentin Jr.",
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create product brand
requires authentication product-brand store
Create a new product brand
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-brands" \
--header "Authorization: Bearer Z5V6Eh3adefa4gk68vbDPc1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-brands"
);
const headers = {
"Authorization": "Bearer Z5V6Eh3adefa4gk68vbDPc1",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update product brand
requires authentication product-brand update
Update a product brand
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/product-brands/sit" \
--header "Authorization: Bearer eD63E41kfgVa58Z6vPhadbc" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-brands/sit"
);
const headers = {
"Authorization": "Bearer eD63E41kfgVa58Z6vPhadbc",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete product brand
requires authentication product-brand delete
Delete a product brand
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/product-brands/est" \
--header "Authorization: Bearer hgeD8c3V56fdZ6P1bEak4av" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-brands/est"
);
const headers = {
"Authorization": "Bearer hgeD8c3V56fdZ6P1bEak4av",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Product Families
Endpoints for product families
List product families
requires authentication product-family index
List all product families
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-families?is_epi=1&q=Structure" \
--header "Authorization: Bearer VhaeP8Ek6D3bf64cZgda1v5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-families"
);
const params = {
"is_epi": "1",
"q": "Structure",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer VhaeP8Ek6D3bf64cZgda1v5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "a39c1eef-99c0-3932-92a8-a62d538a6242",
"name": "Dr. Emanuel Emílio Aragão Sobrinho",
"is_epi": false,
"created_at": null,
"updated_at": null
},
{
"id": "ad11959b-119e-37a3-bbaf-482789c658b1",
"name": "Gian Bittencourt Fontes",
"is_epi": false,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show product family
requires authentication product-family show
Show a product family
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-families/quod" \
--header "Authorization: Bearer P3edZg6kD4fc86ah5Eb1aVv" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-families/quod"
);
const headers = {
"Authorization": "Bearer P3edZg6kD4fc86ah5Eb1aVv",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "4c839c59-c42e-393f-a982-15eaa1416aa1",
"name": "Sra. Samanta Montenegro",
"is_epi": false,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create product family
requires authentication product-family store
Create a new product family
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-families" \
--header "Authorization: Bearer Df51Va86hkegb36EPcZ4vad" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"is_epi\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-families"
);
const headers = {
"Authorization": "Bearer Df51Va86hkegb36EPcZ4vad",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"is_epi": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update product family
requires authentication product-family update
Update a product family
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/product-families/voluptatem" \
--header "Authorization: Bearer 4afZ6k6ae1385bVEvhDdgcP" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"is_epi\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-families/voluptatem"
);
const headers = {
"Authorization": "Bearer 4afZ6k6ae1385bVEvhDdgcP",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"is_epi": true
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete product family
requires authentication product-family delete
Delete a product family
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/product-families/consequuntur" \
--header "Authorization: Bearer VaZEh86v36d1Dfceb4P5gka" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-families/consequuntur"
);
const headers = {
"Authorization": "Bearer VaZEh86v36d1Dfceb4P5gka",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Product Quantity Lists
Endpoints for managing product quantity lists
List product quantity lists
requires authentication product-quantity-list index
List all product quantity lists
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-quantity-lists" \
--header "Authorization: Bearer 6heZP54E3VfdD1gaa8ckvb6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"q\": \"Example Q\",
\"work_id\": \"a7784e93-8348-37db-b632-2d4a3a504640\",
\"user_id\": \"e3108c10-0a49-31ab-ad3c-1d7ed9451ad8\",
\"responsible_id\": \"476910e1-8608-328b-b19a-be693b253640\",
\"per_page\": 1,
\"sort\": \"Example Sort\",
\"sort_desc\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists"
);
const headers = {
"Authorization": "Bearer 6heZP54E3VfdD1gaa8ckvb6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"q": "Example Q",
"work_id": "a7784e93-8348-37db-b632-2d4a3a504640",
"user_id": "e3108c10-0a49-31ab-ad3c-1d7ed9451ad8",
"responsible_id": "476910e1-8608-328b-b19a-be693b253640",
"per_page": 1,
"sort": "Example Sort",
"sort_desc": true
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "9bea448b-835d-3689-a268-37f3f70e959d",
"name": "Porro minus nostrum quia.",
"description": null,
"work": {
"id": "a351a0d5-b6ca-4384-96fa-04fea5bdd4f6",
"name": "Aline Godói Sobrinho"
},
"user": {
"id": "a351a0d5-b999-4a40-9b97-f3c944b83e48",
"name": "Prof. Otilia Konopelski"
},
"created_at": null,
"updated_at": null
},
{
"id": "7f6c3c16-7c1a-3e98-9609-9ac117081315",
"name": "Molestiae aspernatur pariatur consequatur.",
"description": null,
"work": {
"id": "a351a0d5-bd5a-49da-b6b0-c77820f3c290",
"name": "Leonardo Campos Quintana"
},
"user": {
"id": "a351a0d5-c065-42f3-b710-41d66b71679a",
"name": "Ms. Summer Hagenes PhD"
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show product quantity list
requires authentication product-quantity-list show
Show a product quantity list
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/nulla" \
--header "Authorization: Bearer b6hk8c53af6dgVvP4Z1aDeE" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/nulla"
);
const headers = {
"Authorization": "Bearer b6hk8c53af6dgVvP4Z1aDeE",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "fca638a9-537a-38d1-be12-b2ce48cc6f69",
"name": "Quisquam quidem dicta.",
"description": "Voluptates voluptates alias eos omnis suscipit id. Debitis ullam quia ut nam et maiores quis consequatur. Qui vitae eaque enim expedita ullam fuga ea. Rerum est atque voluptatem sapiente placeat.",
"work": {
"id": "a351a0d5-c7eb-490e-b80b-0148f748495d",
"name": "Srta. Márcia Poliana Alves Filho"
},
"user": {
"id": "a351a0d5-cb69-4b97-b4b6-fc8859437590",
"name": "Johnson O'Reilly III"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List items
requires authentication product-quantity-list show
List all items from a product quantity list with pagination
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/voluptatum/items" \
--header "Authorization: Bearer keE536DZVfgPhd684a1abvc" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"per_page\": 1,
\"q\": \"Example Q\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/voluptatum/items"
);
const headers = {
"Authorization": "Bearer keE536DZVfgPhd684a1abvc",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"per_page": 1,
"q": "Example Q"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "59c13999-a769-3afe-b29e-60f7d3b81925",
"product": {
"id": "a351a0d5-e171-4c97-824b-eae75dba22ee",
"name": "Cristiana Santiago Filho",
"code": "PRD-162529",
"unit": {
"id": "a351a0d5-df73-44e2-908d-57da813b61f3",
"name": "Dr. Adriano Carrara Filho",
"abbreviation": "Giovane Rangel Neto"
}
},
"quantity": 805.0489,
"observation": "Beatae totam non reiciendis exercitationem perferendis.",
"created_at": null,
"updated_at": null
},
{
"id": "104f45d7-3f66-3422-b5a7-901015ddae8f",
"product": {
"id": "a351a0d5-f4a9-444a-be82-301653e0ef95",
"name": "Srta. Noa Rico Torres Filho",
"code": "PRD-261666",
"unit": {
"id": "a351a0d5-f320-4b38-8954-a9a91d3021f5",
"name": "Dirce Késia Aragão Neto",
"abbreviation": "Pérola Valdez Pereira Sobrinho"
}
},
"quantity": 689.7267,
"observation": "Itaque ut iusto delectus in accusantium.",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create product quantity list
requires authentication product-quantity-list store
Create a new product quantity list
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists" \
--header "Authorization: Bearer 6vE6gh1PaDe4bkd5Z8afcV3" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"work_id\": \"bf8dda10-0d58-3c37-a43b-ae7c3bc54a02\",
\"items\": [
{
\"product_id\": \"f87bf058-857a-387c-956b-62386a32dcb0\",
\"quantity\": 1,
\"observation\": \"Example Items * observation\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists"
);
const headers = {
"Authorization": "Bearer 6vE6gh1PaDe4bkd5Z8afcV3",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"work_id": "bf8dda10-0d58-3c37-a43b-ae7c3bc54a02",
"items": [
{
"product_id": "f87bf058-857a-387c-956b-62386a32dcb0",
"quantity": 1,
"observation": "Example Items * observation"
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update product quantity list
requires authentication product-quantity-list update
Update a product quantity list. Can include items to replace all items in the list.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/minus" \
--header "Authorization: Bearer 5D184kha6dVaPcv6fbEZ3ge" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"items\": [
{
\"id\": \"30930432-61c9-3020-b18f-11df593f32dd\",
\"product_id\": \"82acacc0-a2fd-3f8b-963e-e3fef14c3037\",
\"quantity\": 1,
\"observation\": \"Example Items * observation\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/minus"
);
const headers = {
"Authorization": "Bearer 5D184kha6dVaPcv6fbEZ3ge",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"items": [
{
"id": "30930432-61c9-3020-b18f-11df593f32dd",
"product_id": "82acacc0-a2fd-3f8b-963e-e3fef14c3037",
"quantity": 1,
"observation": "Example Items * observation"
},
null
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete product quantity list
requires authentication product-quantity-list delete
Delete a product quantity list
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/natus" \
--header "Authorization: Bearer 61kfgbc6h5vaadZPe83VE4D" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/natus"
);
const headers = {
"Authorization": "Bearer 61kfgbc6h5vaadZPe83VE4D",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add items to list
requires authentication product-quantity-list update
Add one or more product items to the list
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/ullam/items" \
--header "Authorization: Bearer abfE4Vg6Ded36acZ15vhP8k" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
{
\"product_id\": \"0b82d0a0-daaa-3c15-8e52-858aa20c8d9d\",
\"quantity\": 1,
\"observation\": \"Example Items * observation\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/ullam/items"
);
const headers = {
"Authorization": "Bearer abfE4Vg6Ded36acZ15vhP8k",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
{
"product_id": "0b82d0a0-daaa-3c15-8e52-858aa20c8d9d",
"quantity": 1,
"observation": "Example Items * observation"
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": "array"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update item
requires authentication product-quantity-list update
Update a product item in the list
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/items/non" \
--header "Authorization: Bearer 5P3g8Zf6vekachEbVaD6d41" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"quantity\": 1,
\"observation\": \"Example Observation\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/items/non"
);
const headers = {
"Authorization": "Bearer 5P3g8Zf6vekachEbVaD6d41",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"quantity": 1,
"observation": "Example Observation"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove items
requires authentication product-quantity-list update
Remove one or more product items from the list
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/quam/items" \
--header "Authorization: Bearer 8E1Zk6aPg3edf54ac6VbDhv" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
\"93e3e68d-2d93-3217-b8a2-a0d690d2c823\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/quam/items"
);
const headers = {
"Authorization": "Bearer 8E1Zk6aPg3edf54ac6VbDhv",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
"93e3e68d-2d93-3217-b8a2-a0d690d2c823"
]
};
fetch(url, {
method: "DELETE",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"deleted": "integer"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Sync items
requires authentication product-quantity-list update
Replace all items in the list
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/molestiae/sync-items" \
--header "Authorization: Bearer P6a8haDg3ckd5f61ZvE4bVe" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
{
\"id\": \"6aa2c9aa-30fd-3375-905e-bd6e1c7727ba\",
\"product_id\": \"3db46946-3c2d-3923-bdca-1fe950d91d03\",
\"quantity\": 1,
\"observation\": \"Example Items * observation\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-quantity-lists/molestiae/sync-items"
);
const headers = {
"Authorization": "Bearer P6a8haDg3ckd5f61ZvE4bVe",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
{
"id": "6aa2c9aa-30fd-3375-905e-bd6e1c7727ba",
"product_id": "3db46946-3c2d-3923-bdca-1fe950d91d03",
"quantity": 1,
"observation": "Example Items * observation"
},
null
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Product Request Fulfillment
Endpoints for fulfilling product request items
Fulfill item
requires authentication product-request fulfill
Fulfill a product request item via transfer or allocation
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-requests/items/magnam/fulfill" \
--header "Authorization: Bearer af1bvd5c8e4gDEP3Zhk6a6V" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"fulfillment_type\": \"Example Fulfillment type\",
\"stock_id\": \"2c7c6074-80ab-3212-8f17-e9092985d074\",
\"quantity\": 1,
\"source_stock_id\": \"06ae3a48-5512-3efc-87ac-e173897404b7\",
\"reason\": \"Example Reason\",
\"origins\": [
{
\"supplier_product_id\": \"254a448b-571f-316a-b179-06ae279743f8\",
\"quantity\": 1
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/items/magnam/fulfill"
);
const headers = {
"Authorization": "Bearer af1bvd5c8e4gDEP3Zhk6a6V",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"fulfillment_type": "Example Fulfillment type",
"stock_id": "2c7c6074-80ab-3212-8f17-e9092985d074",
"quantity": 1,
"source_stock_id": "06ae3a48-5512-3efc-87ac-e173897404b7",
"reason": "Example Reason",
"origins": [
{
"supplier_product_id": "254a448b-571f-316a-b179-06ae279743f8",
"quantity": 1
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List item fulfillments
requires authentication product-request show
List all fulfillments for a product request item
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-requests/items/laudantium/fulfillments" \
--header "Authorization: Bearer g6613v4kVEaafPhdDbeZc85" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"per_page\": 1,
\"page\": 1
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/items/laudantium/fulfillments"
);
const headers = {
"Authorization": "Bearer g6613v4kVEaafPhdDbeZc85",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"per_page": 1,
"page": 1
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "1514267e-78f0-3922-bb63-0ebdab39dbfc",
"quantity": 67.1858,
"fulfilled_at": "2026-10-30T11:52:13.000000Z",
"created_at": null
},
{
"id": "1c22131a-c936-3fdf-92cf-1548d2f7441f",
"quantity": 3.1542,
"fulfilled_at": "2026-11-22T19:27:28.000000Z",
"created_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get item with fulfillment details
requires authentication product-request show
Get a single product request item with its fulfillment details
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-requests/items/adipisci" \
--header "Authorization: Bearer d1h6DacVav5gPkZ3feb84E6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/items/adipisci"
);
const headers = {
"Authorization": "Bearer d1h6DacVav5gPkZ3feb84E6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "16da4823-5aa7-3523-b717-c540966f6f0a",
"product": {
"id": "a351a0d9-ad4e-43fb-99c0-9b7fb62945c5",
"name": "Artur Edilson Delgado",
"code": "PRD-939870",
"unit": {
"id": "a351a0d9-aba2-451d-8d07-c864c8053395",
"name": "Walter Pereira",
"abbreviation": "Dr. Gabrielly Matos Delgado"
}
},
"quantity": 916.1091,
"quantity_fulfilled": 0,
"quantity_pending": 916.1091,
"is_fulfilled": false,
"is_partially_fulfilled": false,
"observation": null,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List pending items
requires authentication product-request show
List all pending items from a product request
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-requests/quam/pending-items" \
--header "Authorization: Bearer 85fevP6DE3g61ahkcbZa4dV" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"per_page\": 1,
\"page\": 1
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/quam/pending-items"
);
const headers = {
"Authorization": "Bearer 85fevP6DE3g61ahkcbZa4dV",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"per_page": 1,
"page": 1
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "b8f4ee1f-a7fb-3b76-9cb9-67869bc330d2",
"product": {
"id": "a351a0d9-cfcb-4a18-8556-d79a781162cf",
"name": "Sra. Isabelly Deverso Aranda",
"code": "PRD-573050",
"unit": {
"id": "a351a0d9-ce4f-4615-91c1-07b7fcbd2418",
"name": "Daniele Vieira",
"abbreviation": "Sr. Thiago Matias da Silva"
}
},
"quantity": 804.1057,
"quantity_fulfilled": 0,
"quantity_pending": 804.1057,
"is_fulfilled": false,
"is_partially_fulfilled": false,
"observation": null,
"created_at": null,
"updated_at": null
},
{
"id": "01088f18-4275-3fe9-be9e-2c2db6b3e341",
"product": {
"id": "a351a0d9-e260-43d8-a9f5-f4ae37785744",
"name": "Estela Karen Abreu Sobrinho",
"code": "PRD-348702",
"unit": {
"id": "a351a0d9-e11f-46c6-832a-f884338d2457",
"name": "Srta. Thalia Elis Rosa Neto",
"abbreviation": "Dr. Samuel Valência Galindo"
}
},
"quantity": 69.6872,
"quantity_fulfilled": 0,
"quantity_pending": 69.6872,
"is_fulfilled": false,
"is_partially_fulfilled": false,
"observation": null,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List pending items by product
requires authentication product-request show
List all pending product request items for a specific product
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-requests/pending-by-product/minus" \
--header "Authorization: Bearer aav65VPkb1d84feEg6h3DZc" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/pending-by-product/minus"
);
const headers = {
"Authorization": "Bearer aav65VPkb1d84feEg6h3DZc",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "11534fcc-fb45-3b2b-90ac-371bb31f3fa8",
"product": {
"id": "a351a0d9-fb42-4062-b6d8-2f5e2a326a68",
"name": "Demian Dener das Neves",
"code": "PRD-526320",
"unit": {
"id": "a351a0d9-f9d9-48c9-8338-8a7ea2f6b650",
"name": "Cristiano Santos Santiago",
"abbreviation": "Sr. Saulo Burgos Fernandes"
}
},
"quantity": 704.3995,
"quantity_fulfilled": 0,
"quantity_pending": 704.3995,
"is_fulfilled": false,
"is_partially_fulfilled": false,
"observation": null,
"created_at": null,
"updated_at": null
},
{
"id": "893372ac-906d-3daa-91b4-5c8464d7ccf4",
"product": {
"id": "a351a0da-0f8a-41d1-89a3-75cc5aef6b02",
"name": "Késia Fernandes",
"code": "PRD-078486",
"unit": {
"id": "a351a0da-0cbf-40e7-9030-15cda79d8c7e",
"name": "Dr. Hosana Fabiana Leon Jr.",
"abbreviation": "Théo Alan Pedrosa"
}
},
"quantity": 236.7259,
"quantity_fulfilled": 0,
"quantity_pending": 236.7259,
"is_fulfilled": false,
"is_partially_fulfilled": false,
"observation": "Voluptas culpa maxime saepe veritatis sed aliquam.",
"created_at": null,
"updated_at": null
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Product Requests
Endpoints for managing product requests for works
List product requests
requires authentication product-request index
List all product requests
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-requests" \
--header "Authorization: Bearer Z61V8vc4fgDhaakb35edE6P" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"sort_by\": \"Example Sort by\",
\"sort_desc\": true,
\"page\": 1,
\"per_page\": 1,
\"q\": \"Example Q\",
\"work_id\": \"fefee1aa-4d3e-3027-b887-e09c402ba844\",
\"work_location_id\": \"52a2e9ac-61fd-30d7-aa1b-f7315ce078fa\",
\"user_id\": \"dd3c1f74-5532-3bb1-861e-c193dd8c5c6b\",
\"status_id\": \"5bcad6d2-c974-316d-b8ce-1797814668f1\",
\"priority\": \"Example Priority\",
\"needed_at_from\": \"Example Needed at from\",
\"needed_at_to\": \"Example Needed at to\",
\"responsible_id\": \"c1e47146-2896-3340-b047-14cb8c8cdabe\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests"
);
const headers = {
"Authorization": "Bearer Z61V8vc4fgDhaakb35edE6P",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"sort_by": "Example Sort by",
"sort_desc": true,
"page": 1,
"per_page": 1,
"q": "Example Q",
"work_id": "fefee1aa-4d3e-3027-b887-e09c402ba844",
"work_location_id": "52a2e9ac-61fd-30d7-aa1b-f7315ce078fa",
"user_id": "dd3c1f74-5532-3bb1-861e-c193dd8c5c6b",
"status_id": "5bcad6d2-c974-316d-b8ce-1797814668f1",
"priority": "Example Priority",
"needed_at_from": "Example Needed at from",
"needed_at_to": "Example Needed at to",
"responsible_id": "c1e47146-2896-3340-b047-14cb8c8cdabe"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "b5645928-8a51-32f2-9c11-9b2ece8e0d0e",
"code": null,
"name": "Pariatur sed eaque.",
"description": "Quo enim sit hic voluptate iste. Vero quidem dolor deserunt veniam aut est et. Natus illo aspernatur enim dolores vero totam rerum. Dolor numquam nihil ullam laboriosam et earum ut modi.",
"work": {
"id": "a351a0d7-5a06-42e2-b58d-6ab2cedec62b",
"name": "Dr. Eduarda Galindo Valentin Jr."
},
"user": {
"id": "a351a0d7-5cfc-44a7-aa77-c3bfc549b880",
"name": "Dr. Cielo Halvorson PhD"
},
"status": {
"id": "a351a0d7-5eec-4a48-af92-8967d068e6e5",
"slug": null,
"name": null,
"description": "Luísa Zaragoça Rodrigues Jr.",
"abbreviation": "cupiditate",
"color": "#6da79b",
"text_color": "#a93470"
},
"priority": "medium",
"priority_label": "Média",
"needed_at": "2026-12-21",
"approved_at": null,
"rejection_reason": null,
"created_at": null,
"updated_at": null
},
{
"id": "bb3095cf-155d-38c9-8fcb-ba52aa967076",
"code": null,
"name": "In voluptatem.",
"description": null,
"work": {
"id": "a351a0d7-6347-4a96-baa4-d4efe8eb8073",
"name": "Samuel José Paes"
},
"user": {
"id": "a351a0d7-662d-4f40-a511-4fdc2ee16420",
"name": "Mrs. Layla Bogan II"
},
"status": {
"id": "a351a0d7-684c-4ca1-ac86-c7032936b139",
"slug": null,
"name": null,
"description": "Srta. Helena Ramires Cervantes",
"abbreviation": "mollitia",
"color": "#6d47fd",
"text_color": "#c00155"
},
"priority": "urgent",
"priority_label": "Urgente",
"needed_at": "2026-12-13",
"approved_at": null,
"rejection_reason": null,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show product request
requires authentication product-request show
Show a product request
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-requests/voluptates" \
--header "Authorization: Bearer k3EZDaf6Veg186c4dbv5aPh" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/voluptates"
);
const headers = {
"Authorization": "Bearer k3EZDaf6Veg186c4dbv5aPh",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "f4e1c57d-45b1-3447-a2cd-3bb58ecd1936",
"code": null,
"name": "Quas in ut.",
"description": null,
"work": {
"id": "a351a0d7-726a-4cbf-b12a-4a6645d2a5db",
"name": "Tatiana Delgado da Cruz"
},
"user": {
"id": "a351a0d7-754b-4eed-ac18-b8cc2e1eb0d9",
"name": "Sonya Dickinson"
},
"status": {
"id": "a351a0d7-7751-497d-a91b-a9be21f79ab7",
"slug": null,
"name": null,
"description": "Carolina Verdara Azevedo",
"abbreviation": "rem",
"color": "#450a90",
"text_color": "#257e4a"
},
"priority": "medium",
"priority_label": "Média",
"needed_at": "2026-12-11",
"approved_at": null,
"rejection_reason": null,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List items
requires authentication product-request show
List all items from a product request with pagination
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/product-requests/autem/items" \
--header "Authorization: Bearer E1vVgckZ8D6ah4a5Pfb63de" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"q\": \"Example Q\",
\"per_page\": 1
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/autem/items"
);
const headers = {
"Authorization": "Bearer E1vVgckZ8D6ah4a5Pfb63de",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"q": "Example Q",
"per_page": 1
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "85aab447-b94d-36d4-9dc9-5d11f7c90214",
"product": {
"id": "a351a0d7-9ed4-4821-9a01-6be19b836b02",
"name": "Isis Lorena Valdez Neto",
"code": "PRD-985967",
"unit": {
"id": "a351a0d7-9d74-4d5a-935f-959f884cff5e",
"name": "Hosana Pacheco Aguiar",
"abbreviation": "Dr. Lidiane Domingues"
}
},
"quantity": 521.6001,
"quantity_fulfilled": 0,
"quantity_pending": 521.6001,
"is_fulfilled": false,
"is_partially_fulfilled": false,
"observation": null,
"created_at": null,
"updated_at": null
},
{
"id": "14ea49f1-eeea-3f0f-adbd-52c223d7c1bb",
"product": {
"id": "a351a0d7-b2f0-4888-8933-5fe95229c774",
"name": "Srta. Emanuelly Giovana da Silva",
"code": "PRD-448380",
"unit": {
"id": "a351a0d7-b1c0-43e4-8e8e-48a434974d90",
"name": "Eduarda Gonçalves Jr.",
"abbreviation": "Diana Sandra Aguiar Filho"
}
},
"quantity": 680.3378,
"quantity_fulfilled": 0,
"quantity_pending": 680.3378,
"is_fulfilled": false,
"is_partially_fulfilled": false,
"observation": "A sed enim doloribus nesciunt quibusdam eaque aspernatur.",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create product request
requires authentication product-request store
Create a new product request
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-requests" \
--header "Authorization: Bearer kef6d3Zva5PaE6DVc841bhg" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"work_id\": \"c58b5500-f117-345a-8512-ecd825ace008\",
\"work_location_id\": \"1ae3ffdf-326d-3890-9cf3-11e26f4b7002\",
\"status_id\": \"feced8b3-10f4-3f2e-ade4-e7a3a87e60f0\",
\"priority\": \"Example Priority\",
\"needed_at\": \"Example Needed at\",
\"items\": [
{
\"product_id\": \"2560fa8c-48e4-3bdf-a6a4-779a7ee973ad\",
\"quantity\": 1,
\"observation\": \"Example Items * observation\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests"
);
const headers = {
"Authorization": "Bearer kef6d3Zva5PaE6DVc841bhg",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"work_id": "c58b5500-f117-345a-8512-ecd825ace008",
"work_location_id": "1ae3ffdf-326d-3890-9cf3-11e26f4b7002",
"status_id": "feced8b3-10f4-3f2e-ade4-e7a3a87e60f0",
"priority": "Example Priority",
"needed_at": "Example Needed at",
"items": [
{
"product_id": "2560fa8c-48e4-3bdf-a6a4-779a7ee973ad",
"quantity": 1,
"observation": "Example Items * observation"
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update product request
requires authentication product-request update
Update a product request. Can include items to replace all items in the request.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/product-requests/quia" \
--header "Authorization: Bearer 5efDEh43Pc1da6Z6kV8gvba" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"work_id\": \"442cdcd9-5758-3604-b3c0-ef4f99854cd7\",
\"work_location_id\": \"158229c1-fcc9-3453-aeae-a34da6d9900a\",
\"status_id\": \"3d938b14-2594-333c-8257-d02540acfa3a\",
\"priority\": \"Example Priority\",
\"needed_at\": \"Example Needed at\",
\"items\": [
{
\"id\": \"55df8455-f2f2-3559-a651-ee9a6a545b90\",
\"product_id\": \"a3628707-59e0-33b8-8b50-9c055a80e1b9\",
\"quantity\": 1,
\"observation\": \"Example Items * observation\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/quia"
);
const headers = {
"Authorization": "Bearer 5efDEh43Pc1da6Z6kV8gvba",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"work_id": "442cdcd9-5758-3604-b3c0-ef4f99854cd7",
"work_location_id": "158229c1-fcc9-3453-aeae-a34da6d9900a",
"status_id": "3d938b14-2594-333c-8257-d02540acfa3a",
"priority": "Example Priority",
"needed_at": "Example Needed at",
"items": [
{
"id": "55df8455-f2f2-3559-a651-ee9a6a545b90",
"product_id": "a3628707-59e0-33b8-8b50-9c055a80e1b9",
"quantity": 1,
"observation": "Example Items * observation"
},
null
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete product request
requires authentication product-request delete
Delete a product request
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/product-requests/illo" \
--header "Authorization: Bearer egvda6VkPcfh54abZ3E81D6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/illo"
);
const headers = {
"Authorization": "Bearer egvda6VkPcfh54abZ3E81D6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Approve product request
requires authentication product-request approve
Approve a product request
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-requests/assumenda/approve" \
--header "Authorization: Bearer fk68Dhacab3PV6Ee1d4Zvg5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/assumenda/approve"
);
const headers = {
"Authorization": "Bearer fk68Dhacab3PV6Ee1d4Zvg5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Reject product request
requires authentication product-request reject
Reject a product request with a reason
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-requests/eaque/reject" \
--header "Authorization: Bearer evP6a4D1Zd5Vc6kh8gbEa3f" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"reason\": \"Example Reason\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/eaque/reject"
);
const headers = {
"Authorization": "Bearer evP6a4D1Zd5Vc6kh8gbEa3f",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"reason": "Example Reason"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add items to request
requires authentication product-request update
Add one or more product items to the request
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/product-requests/consequatur/items" \
--header "Authorization: Bearer 6Eh6k1aa53gb4dVD8cZefPv" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
{
\"product_id\": \"f912a452-233f-30f4-a884-fbab0f066d56\",
\"quantity\": 1,
\"observation\": \"Example Items * observation\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/consequatur/items"
);
const headers = {
"Authorization": "Bearer 6Eh6k1aa53gb4dVD8cZefPv",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
{
"product_id": "f912a452-233f-30f4-a884-fbab0f066d56",
"quantity": 1,
"observation": "Example Items * observation"
},
null
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": "array"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update item
requires authentication product-request update
Update a product item in the request
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/product-requests/items/ut" \
--header "Authorization: Bearer eDkEg61d83ab54fcvh6aZPV" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"quantity\": 1,
\"observation\": \"Example Observation\",
\"status_id\": \"04b69d6f-1a59-3032-af02-8ad69d55f217\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/items/ut"
);
const headers = {
"Authorization": "Bearer eDkEg61d83ab54fcvh6aZPV",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"quantity": 1,
"observation": "Example Observation",
"status_id": "04b69d6f-1a59-3032-af02-8ad69d55f217"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove items
requires authentication product-request update
Remove one or more product items from the request
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/product-requests/similique/items" \
--header "Authorization: Bearer bg3DE8d5v4kcaePZ6aVh16f" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
\"a03f085a-c14c-301d-932e-96329c6b84de\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/similique/items"
);
const headers = {
"Authorization": "Bearer bg3DE8d5v4kcaePZ6aVh16f",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
"a03f085a-c14c-301d-932e-96329c6b84de"
]
};
fetch(url, {
method: "DELETE",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"deleted": "integer"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Sync items
requires authentication product-request update
Replace all items in the request
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/product-requests/est/sync-items" \
--header "Authorization: Bearer ge8Pvh6fZdEakc41b3DaV56" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
{
\"id\": \"6838ab0c-c534-3795-8c91-128c5cb377db\",
\"product_id\": \"9894e5b3-61bf-3086-b8c6-3a231eb430a4\",
\"quantity\": 1,
\"observation\": \"Example Items * observation\"
},
null
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/product-requests/est/sync-items"
);
const headers = {
"Authorization": "Bearer ge8Pvh6fZdEakc41b3DaV56",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
{
"id": "6838ab0c-c534-3795-8c91-128c5cb377db",
"product_id": "9894e5b3-61bf-3086-b8c6-3a231eb430a4",
"quantity": 1,
"observation": "Example Items * observation"
},
null
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": "object"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Products
Endpoints for products
List products
requires authentication product index
List all products
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/products?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Brick&code=PROD-00003&is_epi=1&has_epi_type=" \
--header "Authorization: Bearer g3VcZbD6kv1a4hEfd8aP6e5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/products"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Brick",
"code": "PROD-00003",
"is_epi": "1",
"has_epi_type": "0",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer g3VcZbD6kv1a4hEfd8aP6e5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "27ad18cc-5675-3d53-917a-c66181e06db9",
"name": "Bianca Galindo",
"code": "PRD-075779",
"stock": 59618062,
"product_family": {
"id": "a351a0d5-57c4-4db4-9f41-2ef4c22c3d6c",
"name": "Sr. Danilo Guilherme Soto Filho"
},
"product_brand": {
"id": "a351a0d5-5944-4e5d-9ccc-2cd5af9cbd00",
"name": "Srta. Talita Martines Sobrinho"
},
"unit": {
"id": "a351a0d5-5b01-4b54-830e-7eaf25ca3dae",
"name": "Srta. Naomi Toledo",
"abbreviation": "Kléber Tamoio"
},
"image": {
"id": null,
"url": null
},
"epi_type": null,
"description": "Expedita eos eum est nemo.",
"created_at": null,
"updated_at": null
},
{
"id": "cf06c2cc-2bab-37bd-a30e-e30296fc5bc0",
"name": "Dr. Sarah Valentina Fernandes",
"code": "PRD-570060",
"stock": 76306,
"product_family": {
"id": "a351a0d5-5e6b-44f9-b552-e0a8e731fcdc",
"name": "Sérgio Jimenes Neto"
},
"product_brand": {
"id": "a351a0d5-5fd6-4664-b4a0-ec7ba323db2f",
"name": "Adriele Alessandra Flores Sobrinho"
},
"unit": {
"id": "a351a0d5-614f-4523-888d-75d0aef06714",
"name": "Noa Flores",
"abbreviation": "Sr. Martinho Benites Sobrinho"
},
"image": {
"id": null,
"url": null
},
"epi_type": null,
"description": "Velit rerum sed odit libero sunt facere totam.",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show product
requires authentication product show
Show a product
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/products/1" \
--header "Authorization: Bearer VD6a3e84bac5dPv6gZEhkf1" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/products/1"
);
const headers = {
"Authorization": "Bearer VD6a3e84bac5dPv6gZEhkf1",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "b24c6572-5c9e-374f-931d-c1ff61b97968",
"name": "Dr. Elaine Salas",
"code": "PRD-621299",
"stock": 2923,
"product_family": {
"id": "a351a0d5-69d3-42bd-b3c9-9c631d4bde1b",
"name": "Cezar Flores"
},
"product_brand": {
"id": "a351a0d5-6bb2-49cc-a398-b6a9231d6260",
"name": "Sr. Carlos Ramos"
},
"unit": {
"id": "a351a0d5-6d79-4250-a6d7-61e617d1d4bf",
"name": "Srta. Adriana Uchoa Verdugo Neto",
"abbreviation": "Talita da Cruz Perez"
},
"image": {
"id": null,
"url": null
},
"epi_type": null,
"description": "Qui consequuntur commodi sed iste.",
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List available origins
requires authentication product show
List supplier_products (NF items) with available quantity for the given product, ordered FIFO by NF date.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/products/est/available-origins" \
--header "Authorization: Bearer 6kDc541hPd6a8veba3VZgfE" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/products/est/available-origins"
);
const headers = {
"Authorization": "Bearer 6kDc541hPd6a8veba3VZgfE",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create product
requires authentication product store
Create a new product
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/products" \
--header "Authorization: Bearer e3Va4Pa1vE6ZkcbDg5dhf68" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"product_family_id\": \"5e3a2b94-2f3e-3b2a-b159-0c4a4c0f571a\",
\"product_brand_id\": \"14ad760b-fd97-381d-95d9-0b2dcf10bf69\",
\"unit_id\": \"488211c9-a97b-3086-9746-559b0da8d814\",
\"description\": \"Example Description\",
\"stock\": 1
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/products"
);
const headers = {
"Authorization": "Bearer e3Va4Pa1vE6ZkcbDg5dhf68",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"product_family_id": "5e3a2b94-2f3e-3b2a-b159-0c4a4c0f571a",
"product_brand_id": "14ad760b-fd97-381d-95d9-0b2dcf10bf69",
"unit_id": "488211c9-a97b-3086-9746-559b0da8d814",
"description": "Example Description",
"stock": 1
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update product
requires authentication product update
Update a product
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/products/1" \
--header "Authorization: Bearer 8g4d6hvPV3kefa6cZ1D5Eba" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"product_family_id\": \"9a8c0f4f-dda5-3bed-bcd4-0081728fecb5\",
\"product_brand_id\": \"c53ebef8-e1db-357f-b184-7e5ca2690a75\",
\"unit_id\": \"eb781659-1e58-3721-861a-604fd57c13d7\",
\"stock\": 1,
\"description\": \"Example Description\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/products/1"
);
const headers = {
"Authorization": "Bearer 8g4d6hvPV3kefa6cZ1D5Eba",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"product_family_id": "9a8c0f4f-dda5-3bed-bcd4-0081728fecb5",
"product_brand_id": "c53ebef8-e1db-357f-b184-7e5ca2690a75",
"unit_id": "eb781659-1e58-3721-861a-604fd57c13d7",
"stock": 1,
"description": "Example Description"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete product
requires authentication product delete
Delete a product
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/products/rerum" \
--header "Authorization: Bearer V8Zk6fE1adPv5caheDg364b" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/products/rerum"
);
const headers = {
"Authorization": "Bearer V8Zk6fE1adPv5caheDg364b",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Project Versions
Endpoints for project revisions
Create revision
requires authentication project version
Create a new revision and update the project current file
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/projects/183a3fd4-c4f5-3262-820f-cc6f6682b536/versions" \
--header "Authorization: Bearer 81cZ63egbdaE465PfakDVvh" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"notes\": \"Example Notes\",
\"responsible_user_id\": \"db1b6e6a-140e-33f8-9aa2-cf0f1bdfade6\",
\"file\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example File path\",
\"name\": \"Example Name\",
\"size\": \"Example File size\",
\"extension\": \"Example File extension\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/projects/183a3fd4-c4f5-3262-820f-cc6f6682b536/versions"
);
const headers = {
"Authorization": "Bearer 81cZ63egbdaE465PfakDVvh",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"notes": "Example Notes",
"responsible_user_id": "db1b6e6a-140e-33f8-9aa2-cf0f1bdfade6",
"file": {
"0": "example1",
"1": "example2",
"path": "Example File path",
"name": "Example Name",
"size": "Example File size",
"extension": "Example File extension"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List revisions
requires authentication project show
List all revisions of a project
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/projects/5f0e41e9-4ec0-3cba-8ca5-bcd41eee3b12/versions" \
--header "Authorization: Bearer V34Pachfvk6da1b8Eg6D5Ze" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/projects/5f0e41e9-4ec0-3cba-8ca5-bcd41eee3b12/versions"
);
const headers = {
"Authorization": "Bearer V34Pachfvk6da1b8Eg6D5Ze",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show revision
requires authentication project show
Show a specific revision
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/project-versions/a80a582c-aa59-3595-ad2f-e077255c5f5f" \
--header "Authorization: Bearer E684Zgd3keVabD1c56Pfahv" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/project-versions/a80a582c-aa59-3595-ad2f-e077255c5f5f"
);
const headers = {
"Authorization": "Bearer E684Zgd3keVabD1c56Pfahv",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Download revision
requires authentication project show
Generate a signed URL to download a revision
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/project-versions/63d54a2f-ad9d-3f11-b710-92c544e70cc2/download" \
--header "Authorization: Bearer a5PE4d1kbhafeZV68vD36cg" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/project-versions/63d54a2f-ad9d-3f11-b710-92c544e70cc2/download"
);
const headers = {
"Authorization": "Bearer a5PE4d1kbhafeZV68vD36cg",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"url": "string",
"filename": "string",
"size": "string",
"version_number": "integer"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Restore revision
requires authentication project version
Restore a revision as the current file
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/project-versions/320962dc-369f-3f28-a458-c16e0b726a99/restore" \
--header "Authorization: Bearer dc3DhEVkeg4a61fa856bPZv" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/project-versions/320962dc-369f-3f28-a458-c16e0b726a99/restore"
);
const headers = {
"Authorization": "Bearer dc3DhEVkeg4a61fa856bPZv",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete revision
requires authentication project version
Soft delete a revision
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/project-versions/6bbb3da3-d416-3bb6-aad4-c29c57c5d275" \
--header "Authorization: Bearer 563DkavbgdZf8PcVa64h1eE" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/project-versions/6bbb3da3-d416-3bb6-aad4-c29c57c5d275"
);
const headers = {
"Authorization": "Bearer 563DkavbgdZf8PcVa64h1eE",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Projects
Endpoints for engineering projects
List projects
requires authentication project index
List all projects
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/projects?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=El%C3%A9trico&discipline_id=07a639ca-a4b1-3a49-96ba-24c05661609b&work_id=37876633-2f82-3719-ba6d-3ca0673fa04b&status_id=34a09a84-d493-3375-8996-113e5fd3aee2&responsible_id=86797f82-da33-38af-afe7-3a24d25e11cc" \
--header "Authorization: Bearer VZ6fcv4akd13h6aPegE5bD8" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/projects"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Elétrico",
"discipline_id": "07a639ca-a4b1-3a49-96ba-24c05661609b",
"work_id": "37876633-2f82-3719-ba6d-3ca0673fa04b",
"status_id": "34a09a84-d493-3375-8996-113e5fd3aee2",
"responsible_id": "86797f82-da33-38af-afe7-3a24d25e11cc",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer VZ6fcv4akd13h6aPegE5bD8",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "e79dbeb0-3304-31dd-9850-f7be27244a78",
"name": "Nihil culpa et",
"description": "Expedita id iste ex et modi.",
"current_version": 1,
"file": {
"path": "projects/d76af7d8-6c1a-3375-95b7-80dc381ab9cd.pdf",
"size": "3221187",
"extension": "pdf"
},
"discipline": {
"id": "a351a0da-1b29-4ceb-97b6-7d38344c8305",
"name": "Dignissimos",
"code": "ZSD"
},
"created_at": null,
"updated_at": null
},
{
"id": "c0571b74-f59f-342e-8c69-155281feebf2",
"name": "Voluptatem eligendi ea",
"description": "Et dolor qui quo accusamus tenetur praesentium.",
"current_version": 1,
"file": {
"path": "projects/35b411c6-27d9-3042-9b8c-cf3ce3338bb0.pdf",
"size": "4732433",
"extension": "pdf"
},
"discipline": {
"id": "a351a0da-20c3-4a18-8c9d-ebbac67e992a",
"name": "Aut",
"code": "CLW"
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show project
requires authentication project show
Show a project
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/projects/17" \
--header "Authorization: Bearer 86f5v4adbceVg1kD6EhZP3a" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/projects/17"
);
const headers = {
"Authorization": "Bearer 86f5v4adbceVg1kD6EhZP3a",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "0e7b6bd4-aa79-3e77-a64b-70ff043e9cbc",
"name": "Nobis illum neque",
"description": "Molestias sunt maxime soluta laudantium.",
"current_version": 1,
"file": {
"path": "projects/51a5efe8-bebe-3aa6-b652-5a93e4abdf47.pdf",
"size": "716574",
"extension": "pdf"
},
"discipline": {
"id": "a351a0da-28ee-41f9-9d37-f941029a2643",
"name": "Suscipit",
"code": "CNK"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create project
requires authentication project store
Create a new project and its first revision (R00)
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/projects" \
--header "Authorization: Bearer 3g86ZVPvbaehd1k54aE6fDc" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"discipline_id\": \"7f98c5c5-c700-3969-9d57-28cfd2272a48\",
\"work_id\": \"2a8afb94-bc91-364a-93b1-53025c234d5d\",
\"responsible_user_id\": \"086a0caa-cdf0-3dbe-9d98-293da41bfd3d\",
\"notes\": \"Example Notes\",
\"file\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example File path\",
\"name\": \"Example Name\",
\"size\": \"Example File size\",
\"extension\": \"Example File extension\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/projects"
);
const headers = {
"Authorization": "Bearer 3g86ZVPvbaehd1k54aE6fDc",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"discipline_id": "7f98c5c5-c700-3969-9d57-28cfd2272a48",
"work_id": "2a8afb94-bc91-364a-93b1-53025c234d5d",
"responsible_user_id": "086a0caa-cdf0-3dbe-9d98-293da41bfd3d",
"notes": "Example Notes",
"file": {
"0": "example1",
"1": "example2",
"path": "Example File path",
"name": "Example Name",
"size": "Example File size",
"extension": "Example File extension"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update project
requires authentication project update
Update a project (metadata only)
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/projects/3" \
--header "Authorization: Bearer v68fg3bEVaah1Zc4eP65Ddk" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"discipline_id\": \"5d2ef72e-561e-3fd6-b3ed-a17b93d1a624\",
\"work_id\": \"e634fa54-4341-36d8-be8d-c851870cfe01\",
\"responsible_user_id\": \"00828a4c-f0a7-3145-9c1a-027981b7af69\",
\"status_id\": \"981edb7e-e986-3dd8-93aa-72c7d17bd7e2\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/projects/3"
);
const headers = {
"Authorization": "Bearer v68fg3bEVaah1Zc4eP65Ddk",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"discipline_id": "5d2ef72e-561e-3fd6-b3ed-a17b93d1a624",
"work_id": "e634fa54-4341-36d8-be8d-c851870cfe01",
"responsible_user_id": "00828a4c-f0a7-3145-9c1a-027981b7af69",
"status_id": "981edb7e-e986-3dd8-93aa-72c7d17bd7e2"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete project
requires authentication project delete
Delete a project and its revisions
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/projects/ab" \
--header "Authorization: Bearer Z4cEh1Vfd6b63DvP85gkaae" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/projects/ab"
);
const headers = {
"Authorization": "Bearer Z4cEh1Vfd6b63DvP85gkaae",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Reports
Endpoints for reports
Generate RDO PDF
requires authentication daily-log show
Dispatches async PDF generation. Frontend receives notification via Pusher when ready.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/daily-log" \
--header "Authorization: Bearer vcgPZa16k5eaEDbVh6d43f8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"daily_log\": \"accusantium\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/daily-log"
);
const headers = {
"Authorization": "Bearer vcgPZa16k5eaEDbVh6d43f8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"daily_log": "accusantium"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate EPI term PDF
requires authentication employee-epi show
Dispatches async PDF generation. Frontend receives notification via Pusher when ready.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/epi-term" \
--header "Authorization: Bearer vPh85Egc46bZ1kaDfV36ade" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"employee\": \"commodi\",
\"kit_uuid\": \"b40bcf94-8188-3b64-a2f4-7a513c0c0c2e\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/epi-term"
);
const headers = {
"Authorization": "Bearer vPh85Egc46bZ1kaDfV36ade",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"employee": "commodi",
"kit_uuid": "b40bcf94-8188-3b64-a2f4-7a513c0c0c2e"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate payroll sheets PDF
requires authentication No specific permission required
Gera o PDF das folhas cuja data de pagamento cai no período, com os itens por pessoa e obra e os subtotais por obra e por forma de pagamento. Folha ainda em rascunho sai marcada como não conferida. A geração é assíncrona: o front é avisado por Pusher quando fica pronto.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/payroll-sheet" \
--header "Authorization: Bearer 6f6Vg458abZ3akhdevcP1DE" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"start\": \"2026-11-26\",
\"end\": \"2107-11-18\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/payroll-sheet"
);
const headers = {
"Authorization": "Bearer 6f6Vg458abZ3akhdevcP1DE",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"start": "2026-11-26",
"end": "2107-11-18"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (202):
{
"message": "PDF da folha sendo gerado. Você será notificado quando estiver pronto.",
"channel": "reports.uuid",
"event": "pdf-report.completed"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate day payments Excel
requires authentication payroll pay
Gera a planilha de "Pagamentos do dia": uma linha por item, com favorecido, documento, chave PIX, obra, centro de custo, folha, forma, valor (diária mais acréscimos) e situação. Sem date, usa o dia de hoje. A geração é assíncrona: o front é avisado por Pusher quando fica pronta.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/payroll-day/excel" \
--header "Authorization: Bearer bP6h1ea6ak85EdVfvcZ3g4D" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"date\": \"2026-11-26\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/payroll-day/excel"
);
const headers = {
"Authorization": "Bearer bP6h1ea6ak85EdVfvcZ3g4D",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"date": "2026-11-26"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (202):
{
"message": "Planilha sendo gerada. Você será notificado quando estiver pronta.",
"channel": "reports.uuid",
"event": "excel-report.completed"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate employee sheet PDF
requires authentication No specific permission required
Dispatches async PDF generation of the employee record. Frontend receives notification via Pusher when ready.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/employee-sheet" \
--header "Authorization: Bearer ha6kb813Zv6Df5VgaEd4cPe" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"employee\": \"rerum\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/employee-sheet"
);
const headers = {
"Authorization": "Bearer ha6kb813Zv6Df5VgaEd4cPe",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"employee": "rerum"
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cost center panel
requires authentication cost-center report
Totais por centro de custo no período, somados pela árvore. Devolve dois blocos declarados e separados: desembolso (fecha com o caixa e o banco) e custo apropriado por obra. Os dois não se somam — material comprado num mês e entregue em outro aparece em cada bloco no seu momento.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/cost-center?date_start=2026-11-01&date_end=2026-11-30&works[]=a4a5b137-d390-3bc0-b853-4d78d25f8bf1&cost_centers[]=d4159869-06f1-3913-875b-ffdcb61dca94&format=xlsx" \
--header "Authorization: Bearer a66vkf4da1ZPE5Veg3b8chD" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/cost-center"
);
const params = {
"date_start": "2026-11-01",
"date_end": "2026-11-30",
"works[0]": "a4a5b137-d390-3bc0-b853-4d78d25f8bf1",
"cost_centers[0]": "d4159869-06f1-3913-875b-ffdcb61dca94",
"format": "xlsx",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer a66vkf4da1ZPE5Veg3b8chD",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cost center entries
requires authentication cost-center report
Lançamentos que formam um total do painel, paginados e em ordem de data. O centro informado inclui a subárvore, então clicar no total de um grupo lista o que veio dos filhos também.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/cost-center/entries?search=commodi&sort_by=date&sort_desc=1&per_page=16" \
--header "Authorization: Bearer aZd1hVf4D3g6v6Pbe8a5cEk" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"date_start\": \"2026-11-26\",
\"date_end\": \"2090-01-05\",
\"block\": \"work_cost\",
\"cost_center_id\": \"e63a2019-793b-362e-9cfc-c03ce2317ba1\",
\"without_cost_center\": false,
\"type\": \"labor\",
\"per_page\": 9,
\"search\": \"zhwblidtaiilftobua\",
\"sort_by\": \"amount\",
\"sort_desc\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/cost-center/entries"
);
const params = {
"search": "commodi",
"sort_by": "date",
"sort_desc": "1",
"per_page": "16",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer aZd1hVf4D3g6v6Pbe8a5cEk",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"date_start": "2026-11-26",
"date_end": "2090-01-05",
"block": "work_cost",
"cost_center_id": "e63a2019-793b-362e-9cfc-c03ce2317ba1",
"without_cost_center": false,
"type": "labor",
"per_page": 9,
"search": "zhwblidtaiilftobua",
"sort_by": "amount",
"sort_desc": true
};
fetch(url, {
method: "GET",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Export cost center panel
requires authentication cost-center report
Gera a planilha do painel com os filtros atuais. XLSX sai com três abas (um total por bloco, mais os lançamentos); CSV sai com as mesmas três coisas em seções. O arquivo é gerado em fila e chega por notificação.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/cost-center/excel?date_start=2026-11-01&date_end=2026-11-30&works[]=9dbc3e83-96be-3952-8735-43aaf35537b1&cost_centers[]=3d75dd7d-2bbd-369d-8127-d530fe063510&format=xlsx" \
--header "Authorization: Bearer eVv184fE3DkaaPZdch6b5g6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/cost-center/excel"
);
const params = {
"date_start": "2026-11-01",
"date_end": "2026-11-30",
"works[0]": "9dbc3e83-96be-3952-8735-43aaf35537b1",
"cost_centers[0]": "3d75dd7d-2bbd-369d-8127-d530fe063510",
"format": "xlsx",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer eVv184fE3DkaaPZdch6b5g6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (202):
{
"message": "Relatório sendo gerado. Você será notificado quando estiver pronto.",
"channel": "reports.{uuid}",
"event": "excel-report.completed"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Export Cash Flow to Excel
requires authentication No specific permission required
Dispatches async Excel generation. Frontend receives notification via Pusher when ready.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/cash-flow/excel?q=iste&type=entrada&description=Fugiat+exercitationem+enim+nulla+omnis+magni+consequuntur.&categories[]=55627a62-9cae-39bb-90ff-78842ad6970d&exclude_categories[]=ed677033-271f-33e2-816e-60e358a16ca2&date_start=2026-01-01&date_end=2026-12-31&bank_accounts[]=1d89ab63-6928-3c26-ae62-63fb6a415524&customers[]=83c6063f-f6c3-30b4-93c0-d064bb5aec45&suppliers[]=35bd4f13-f466-38a0-8589-b12ca940247a&cash_session=55d08b37-1573-310e-82a6-85b28677810e&works[]=de0bd77e-e2ab-3a19-8091-cf2fa4b7ea74" \
--header "Authorization: Bearer f5VbveaZcgE641d8aDP36kh" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/cash-flow/excel"
);
const params = {
"q": "iste",
"type": "entrada",
"description": "Fugiat exercitationem enim nulla omnis magni consequuntur.",
"categories[0]": "55627a62-9cae-39bb-90ff-78842ad6970d",
"exclude_categories[0]": "ed677033-271f-33e2-816e-60e358a16ca2",
"date_start": "2026-01-01",
"date_end": "2026-12-31",
"bank_accounts[0]": "1d89ab63-6928-3c26-ae62-63fb6a415524",
"customers[0]": "83c6063f-f6c3-30b4-93c0-d064bb5aec45",
"suppliers[0]": "35bd4f13-f466-38a0-8589-b12ca940247a",
"cash_session": "55d08b37-1573-310e-82a6-85b28677810e",
"works[0]": "de0bd77e-e2ab-3a19-8091-cf2fa4b7ea74",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer f5VbveaZcgE641d8aDP36kh",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
GET api/reports/cash-flow
No specific permission required
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/cash-flow?q=earum&type=entrada&description=Consequatur+et+in+debitis+illum+quisquam+et.&categories[]=fe9f5c00-376d-3b4d-b093-14f9d0fe1327&exclude_categories[]=83b387f2-0e5d-3f8d-b24e-7a74dd8feab6&date_start=2026-01-01&date_end=2026-12-31&bank_accounts[]=433596bc-2f99-3f61-9454-266f30511af1&customers[]=ef1b7432-9dd4-3fec-aa93-06cc50fdaf8a&suppliers[]=a29dbc02-1e77-3202-a89e-aac28d448466&cash_session=6d4080bf-2c93-3c3d-9c77-5c339719804a&works[]=25f8224b-dcc1-33f8-b06b-e3692b17a48a" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/cash-flow"
);
const params = {
"q": "earum",
"type": "entrada",
"description": "Consequatur et in debitis illum quisquam et.",
"categories[0]": "fe9f5c00-376d-3b4d-b093-14f9d0fe1327",
"exclude_categories[0]": "83b387f2-0e5d-3f8d-b24e-7a74dd8feab6",
"date_start": "2026-01-01",
"date_end": "2026-12-31",
"bank_accounts[0]": "433596bc-2f99-3f61-9454-266f30511af1",
"customers[0]": "ef1b7432-9dd4-3fec-aa93-06cc50fdaf8a",
"suppliers[0]": "a29dbc02-1e77-3202-a89e-aac28d448466",
"cash_session": "6d4080bf-2c93-3c3d-9c77-5c339719804a",
"works[0]": "25f8224b-dcc1-33f8-b06b-e3692b17a48a",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Export Accounts Payable/Receivable to Excel
requires authentication No specific permission required
Dispatches async Excel generation. Frontend receives notification via Pusher when ready.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/accounts-payable-receivable/excel" \
--header "Authorization: Bearer hgPvEae5f4ZDdVk38c16ba6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/accounts-payable-receivable/excel"
);
const headers = {
"Authorization": "Bearer hgPvEae5f4ZDdVk38c16ba6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
GET api/reports/accounts-payable-receivable
No specific permission required
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/reports/accounts-payable-receivable" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/reports/accounts-payable-receivable"
);
const headers = {
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (401):
Show headers
cache-control: no-cache, private
content-type: application/json
vary: Origin
{
"message": "Unauthenticated."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Sectors
Endpoints for sectors
List sectors
requires authentication sector index
List all sectors
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/sectors?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Tecnologia" \
--header "Authorization: Bearer PZ5e46D8kdaEhgvV1a6bfc3" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Tecnologia",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer PZ5e46D8kdaEhgvV1a6bfc3",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "d60667d5-8d7f-3ae3-9fd1-1cb50e18f3d9",
"name": "nulla et",
"slug": null,
"description": "Omnis laboriosam impedit nostrum eum amet. Quod enim eius ut ad quia adipisci cupiditate. Qui consequatur blanditiis eaque veniam. Enim autem a ipsa distinctio.",
"abbreviation": null,
"created_at": null,
"updated_at": null
},
{
"id": "df33d01f-7e05-32ef-aca8-f0c586d804b9",
"name": "pariatur ut",
"slug": null,
"description": "Aut voluptatem natus neque perspiciatis nulla eum molestias. Eum quidem ea dolorem quis alias qui provident. Adipisci reiciendis et illum molestias voluptatem.",
"abbreviation": "lzq",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create sector
requires authentication sector store
Create a new sector
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/sectors" \
--header "Authorization: Bearer 6faa8c3E1e4gDdVhkv5ZbP6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"slug\": \"Example Slug\",
\"description\": \"Example Description\",
\"abbreviation\": \"Example Abbreviation\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"url\": \"https:\\/\\/example.com\",
\"name\": \"Example Name\",
\"size\": \"Example Image size\",
\"extension\": \"Example Image extension\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors"
);
const headers = {
"Authorization": "Bearer 6faa8c3E1e4gDdVhkv5ZbP6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"slug": "Example Slug",
"description": "Example Description",
"abbreviation": "Example Abbreviation",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"url": "https:\/\/example.com",
"name": "Example Name",
"size": "Example Image size",
"extension": "Example Image extension"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get sector
requires authentication sector show
Get a sector
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/sectors/11" \
--header "Authorization: Bearer 4aDPZEV31ck56hbagd68vef" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors/11"
);
const headers = {
"Authorization": "Bearer 4aDPZEV31ck56hbagd68vef",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "535e8906-d949-3e13-bad2-6635f5a2a6f7",
"name": "ut sit",
"slug": null,
"description": null,
"abbreviation": "pnw",
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update sector
requires authentication sector update
Update a sector
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/sectors/8" \
--header "Authorization: Bearer b5Dk8Vava1eZEfgPc4d3h66" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"slug\": \"Example Slug\",
\"description\": \"Example Description\",
\"abbreviation\": \"Example Abbreviation\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"url\": \"https:\\/\\/example.com\",
\"name\": \"Example Name\",
\"size\": \"Example Image size\",
\"extension\": \"Example Image extension\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors/8"
);
const headers = {
"Authorization": "Bearer b5Dk8Vava1eZEfgPc4d3h66",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"slug": "Example Slug",
"description": "Example Description",
"abbreviation": "Example Abbreviation",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"url": "https:\/\/example.com",
"name": "Example Name",
"size": "Example Image size",
"extension": "Example Image extension"
}
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete sector
requires authentication sector delete
Delete a sector
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/sectors/8" \
--header "Authorization: Bearer 3V51eEkgZfa4bc6P8aD6vhd" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors/8"
);
const headers = {
"Authorization": "Bearer 3V51eEkgZfa4bc6P8aD6vhd",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List sector users
requires authentication sector show
List all users assigned to a sector
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/sectors/019556e7-2e9f-777c-a177-30bbf0646c32/users" \
--header "Authorization: Bearer gv6Vab8PE4afk1h5e3cDd6Z" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors/019556e7-2e9f-777c-a177-30bbf0646c32/users"
);
const headers = {
"Authorization": "Bearer gv6Vab8PE4afk1h5e3cDd6Z",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "3daa8810-c386-38e5-aaf7-76155b654031",
"name": "Berenice Sawayn",
"username": "uorn",
"email": "berge.laila@example.net",
"certification": null,
"crea": null,
"last_login_at": null,
"image": {
"id": null,
"url": null
},
"sectors": [],
"roles": []
},
{
"id": "9e88a637-0416-3db4-8bdc-e3eb70e1dbac",
"name": "Karolann Glover",
"username": "altenwerth.esta",
"email": "elenor28@example.net",
"certification": null,
"crea": null,
"last_login_at": null,
"image": {
"id": null,
"url": null
},
"sectors": [],
"roles": []
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Attach users to sector
requires authentication sector users attach
Attach users to a sector without removing existing ones. Expects an array of user UUIDs in the "users" field.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/sectors/019556e7-2e9f-777c-a177-30bbf0646c32/users/attach" \
--header "Authorization: Bearer ZEV61d653eDvcaa8hfk4bPg" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"users\": [
\"721eb940-729e-36a1-9f68-552f790d30ed\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors/019556e7-2e9f-777c-a177-30bbf0646c32/users/attach"
);
const headers = {
"Authorization": "Bearer ZEV61d653eDvcaa8hfk4bPg",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"users": [
"721eb940-729e-36a1-9f68-552f790d30ed"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Users attached successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Detach users from sector
requires authentication sector users detach
Remove specific users from a sector. Expects an array of user UUIDs in the "users" field.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/sectors/019556e7-2e9f-777c-a177-30bbf0646c32/users/detach" \
--header "Authorization: Bearer dPVfh3k5g41EebvaDc6a68Z" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"users\": [
\"f09aad12-0fef-34e3-9f30-f312ea5ecd77\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors/019556e7-2e9f-777c-a177-30bbf0646c32/users/detach"
);
const headers = {
"Authorization": "Bearer dPVfh3k5g41EebvaDc6a68Z",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"users": [
"f09aad12-0fef-34e3-9f30-f312ea5ecd77"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Users detached successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Sync sector users
requires authentication sector users sync
Replace all sector users with the provided list. Expects an array of user UUIDs in the "users" field.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/sectors/019556e7-2e9f-777c-a177-30bbf0646c32/users/sync" \
--header "Authorization: Bearer 5PD3decvE1V8ab4hfZk6g6a" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"users\": [
\"f49e4f6c-553d-357d-b0ad-de04ea223152\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/sectors/019556e7-2e9f-777c-a177-30bbf0646c32/users/sync"
);
const headers = {
"Authorization": "Bearer 5PD3decvE1V8ab4hfZk6g6a",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"users": [
"f49e4f6c-553d-357d-b0ad-de04ea223152"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Users synchronized successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Status Modules
Endpoints for modules that have status
List status modules
requires authentication status index
List all modules that have status functionality
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/status-modules" \
--header "Authorization: Bearer fPVdv6c8ehgE345b16DaZak" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/status-modules"
);
const headers = {
"Authorization": "Bearer fPVdv6c8ehgE345b16DaZak",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"name": "voluptatibus laborum",
"slug": "magnam-minima-est-suscipit-non-nostrum"
},
{
"name": "facilis ut",
"slug": "earum-dolorem-consequuntur-in-quidem-iste"
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Statuses
Endpoints for statuses
List statuses
requires authentication status index
List all statuses
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/statuses?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Em+andamento&module=work§or_id=019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer 614dhcaf8ebagEZv3Vk5PD6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/statuses"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Em andamento",
"module": "work",
"sector_id": "019556e7-2e9f-777c-a177-30bbf0646c32",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 614dhcaf8ebagEZv3Vk5PD6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "77d01942-dccf-3a2f-bd4d-d5182b7f7487",
"slug": null,
"name": null,
"description": "Sr. Cristóvão Maicon de Aguiar",
"abbreviation": "dolorem",
"color": "#6f29ac",
"text_color": "#61d7a9",
"created_at": null,
"updated_at": null
},
{
"id": "632fce92-f289-30a4-aba7-af86c3018693",
"slug": null,
"name": null,
"description": "Vanessa Zamana Galhardo",
"abbreviation": "facilis",
"color": "#6866cc",
"text_color": "#9e3523",
"module": {
"name": "Solicitação de Produtos",
"slug": "product_request"
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create status
requires authentication status store
Create a new status
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/statuses" \
--header "Authorization: Bearer c686ae4PDkE1Vbdva5Zhf3g" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"slug\": \"Example Slug\",
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"abbreviation\": \"Example Abbreviation\",
\"module\": \"Example Module\",
\"sector_id\": \"8b15225a-9f9f-392a-b4bc-dd75f5f62517\",
\"color\": \"Example Color\",
\"text_color\": \"Example Text color\",
\"order\": 1,
\"is_initial\": true,
\"is_final\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/statuses"
);
const headers = {
"Authorization": "Bearer c686ae4PDkE1Vbdva5Zhf3g",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"slug": "Example Slug",
"name": "Example Name",
"description": "Example Description",
"abbreviation": "Example Abbreviation",
"module": "Example Module",
"sector_id": "8b15225a-9f9f-392a-b4bc-dd75f5f62517",
"color": "Example Color",
"text_color": "Example Text color",
"order": 1,
"is_initial": true,
"is_final": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get status
requires authentication status show
Get a status
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/statuses/1" \
--header "Authorization: Bearer V8e3456b1ZPc6gadEDvahkf" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/statuses/1"
);
const headers = {
"Authorization": "Bearer V8e3456b1ZPc6gadEDvahkf",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "dde24b85-c3c1-3544-94df-d39176a80dd5",
"slug": null,
"name": null,
"description": "Aurora Quintana Filho",
"abbreviation": "et",
"color": "#e70498",
"text_color": "#98ee3c",
"module": {
"name": "Solicitação de Produtos",
"slug": "product_request"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update status
requires authentication status update
Update a status
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/statuses/1" \
--header "Authorization: Bearer 6vdk18agZ6ecPb4hD5Ef3aV" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"slug\": \"Example Slug\",
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"abbreviation\": \"Example Abbreviation\",
\"module\": \"Example Module\",
\"sector_id\": \"22adb7c1-b3e0-3846-83c0-2222a47ae297\",
\"color\": \"Example Color\",
\"text_color\": \"Example Text color\",
\"order\": 1,
\"is_initial\": true,
\"is_final\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/statuses/1"
);
const headers = {
"Authorization": "Bearer 6vdk18agZ6ecPb4hD5Ef3aV",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"slug": "Example Slug",
"name": "Example Name",
"description": "Example Description",
"abbreviation": "Example Abbreviation",
"module": "Example Module",
"sector_id": "22adb7c1-b3e0-3846-83c0-2222a47ae297",
"color": "Example Color",
"text_color": "Example Text color",
"order": 1,
"is_initial": true,
"is_final": true
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete status
requires authentication status delete
Delete a status
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/statuses/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer eV5a1EDP3cb4v6da8h6kgZf" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/statuses/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer eV5a1EDP3cb4v6da8h6kgZf",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Stock
Endpoints for stock management
List stocks available for transfer
requires authentication stock index
Returns a list of stock items from other works that have the specified product available for transfer
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/stocks/available-for-transfer?product_id=019556e7-2e9f-777c-a177-30bbf0646c32&exclude_work_id=019556e7-2e9f-777c-a177-30bbf0646c33&min_quantity=1" \
--header "Authorization: Bearer 5kePd4Zh6a6gvVfb3Ea1c8D" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/available-for-transfer"
);
const params = {
"product_id": "019556e7-2e9f-777c-a177-30bbf0646c32",
"exclude_work_id": "019556e7-2e9f-777c-a177-30bbf0646c33",
"min_quantity": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 5kePd4Zh6a6gvVfb3Ea1c8D",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "b509b7af-4b8c-3702-8c71-bb15376ca321",
"quantity": 876.6684,
"min_quantity": null,
"max_quantity": null,
"below_minimum": false,
"above_maximum": false,
"created_at": null,
"updated_at": null
},
{
"id": "0c80b685-51c5-3125-ad68-7d3978823bf5",
"quantity": 659.6211,
"min_quantity": null,
"max_quantity": null,
"below_minimum": false,
"above_maximum": false,
"created_at": null,
"updated_at": null
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List stocks
requires authentication stock index
Returns a paginated list of stocks
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/stocks?sort_by=created_at&sort_desc=1&page=1&per_page=10&q=Main+Stock&module=work&is_active=1" \
--header "Authorization: Bearer b14Ddk86PahgE6eaVcvZ5f3" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "10",
"q": "Main Stock",
"module": "work",
"is_active": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer b14Ddk86PahgE6eaVcvZ5f3",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "9087bb6f-d779-3a74-b765-57ac66812d26",
"name": "Estoque Quintana Comercial Ltda.",
"module": "work",
"is_active": true,
"is_main": false,
"created_at": null,
"updated_at": null
},
{
"id": "50270299-4957-3fbe-a17c-aedac32fd38e",
"name": "Estoque Galindo e D'ávila",
"module": "work",
"is_active": true,
"is_main": false,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create stock
requires authentication stock store
Creates a new stock linked to a module
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/stocks" \
--header "Authorization: Bearer h6gEv3eaZ86cfd4DP51Vkab" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"module\": \"Example Module\",
\"id\": \"Example Id\",
\"is_active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks"
);
const headers = {
"Authorization": "Bearer h6gEv3eaZ86cfd4DP51Vkab",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"module": "Example Module",
"id": "Example Id",
"is_active": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "68f80a95-cbac-3783-b076-bf1cf6705535",
"name": "Estoque Barros e Souza e Associados",
"module": "work",
"is_active": true,
"is_main": false,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get main stock
requires authentication stock.main show
Returns the main stock
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/stocks/main" \
--header "Authorization: Bearer hbZaVgd4kcafE56ePv8D613" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/main"
);
const headers = {
"Authorization": "Bearer hbZaVgd4kcafE56ePv8D613",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "a80ae1c8-c95d-33c5-8fa4-8fe65630b6cd",
"name": "Estoque Amaral Comercial Ltda.",
"module": "work",
"is_active": true,
"is_main": false,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show stock
requires authentication stock show
Returns details of a specific stock
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/stocks/1" \
--header "Authorization: Bearer fh6c1dbZ86D4EP5a3vagkeV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/1"
);
const headers = {
"Authorization": "Bearer fh6c1dbZ86D4EP5a3vagkeV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "1c2964d4-7d10-3285-bdce-41835002ff25",
"name": "Estoque Neves e Jimenes S.A.",
"module": "work",
"is_active": true,
"is_main": false,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update stock
requires authentication stock update
Updates an existing stock
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/stocks/1" \
--header "Authorization: Bearer Dbkgv8Vd3aaP4Zc6Ef5eh16" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"is_active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/1"
);
const headers = {
"Authorization": "Bearer Dbkgv8Vd3aaP4Zc6Ef5eh16",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"is_active": true
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "b82ac35c-a41b-36c6-b34c-1961e8fc85c5",
"name": "Estoque Sanches e Associados",
"module": "work",
"is_active": true,
"is_main": false,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete stock
requires authentication stock delete
Removes a stock (soft delete)
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/stocks/1" \
--header "Authorization: Bearer Pfg6h5E3aacbe6d81ZDvk4V" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/1"
);
const headers = {
"Authorization": "Bearer Pfg6h5E3aacbe6d81ZDvk4V",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List stock items
requires authentication stock show
Returns a paginated list of items/products in a stock
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/stocks/019556e7-2e9f-777c-a177-30bbf0646c32/items?sort_by=created_at&sort_desc=1&page=1&per_page=10&q=Cement&below_minimum=1&above_maximum=" \
--header "Authorization: Bearer 3kZ6ab14Dcfhav8gdePEV65" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/019556e7-2e9f-777c-a177-30bbf0646c32/items"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "10",
"q": "Cement",
"below_minimum": "1",
"above_maximum": "0",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 3kZ6ab14Dcfhav8gdePEV65",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "03b0174d-e559-3e6b-8194-43ad6b1d8d04",
"quantity": 461.6318,
"min_quantity": null,
"max_quantity": null,
"below_minimum": false,
"above_maximum": false,
"created_at": null,
"updated_at": null
},
{
"id": "c5fe33fd-5052-36b3-b15c-75292cf19390",
"quantity": 733.5689,
"min_quantity": null,
"max_quantity": null,
"below_minimum": false,
"above_maximum": false,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update stock item
requires authentication stock update
Updates min/max quantity thresholds for a stock item
Example request:
curl --request PATCH \
"https://api.bs-homolog.pensou.app.br/api/stocks/1/items/earum" \
--header "Authorization: Bearer bD3kEaPc54eZhd6v186agVf" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"min_quantity\": 10,
\"max_quantity\": 100
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/1/items/earum"
);
const headers = {
"Authorization": "Bearer bD3kEaPc54eZhd6v186agVf",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"min_quantity": 10,
"max_quantity": 100
};
fetch(url, {
method: "PATCH",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "bf28f96c-5243-3e37-8afa-f08e386bdba9",
"quantity": 45.3862,
"min_quantity": null,
"max_quantity": null,
"below_minimum": false,
"above_maximum": false,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Stock summary
requires authentication stock show
Returns a summary with totals and alerts for the stock
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/stocks/019556e7-2e9f-777c-a177-30bbf0646c32/summary" \
--header "Authorization: Bearer k5ZaVabDgvdh1fE8c4P63e6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/019556e7-2e9f-777c-a177-30bbf0646c32/summary"
);
const headers = {
"Authorization": "Bearer k5ZaVabDgvdh1fE8c4P63e6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"total_products": 15,
"total_quantity": 1250.5,
"total_value": 18750.4,
"current_value": 9000,
"consumed_value": 9750.4,
"unvalued_quantity": 5,
"items_below_minimum": 3,
"items_above_maximum": 1
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Stock Movements
Endpoints for stock movement management
List movements
requires authentication stock.movement index
Returns a paginated list of movements for a stock
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/stocks/1/movements?sort_by=created_at&sort_desc=1&page=1&per_page=10&type=entry&product_id=019556e7-2e9f-777c-a177-30bbf0646c32&date_start=2024-01-01&date_end=2024-12-31" \
--header "Authorization: Bearer VhDe8avd51bg43fEZac66Pk" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/1/movements"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "10",
"type": "entry",
"product_id": "019556e7-2e9f-777c-a177-30bbf0646c32",
"date_start": "2024-01-01",
"date_end": "2024-12-31",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer VhDe8avd51bg43fEZac66Pk",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "c0615148-8eb0-30d5-b075-0514ecd7e35a",
"code": "MOV-330436",
"type": "devolução",
"type_name": "RETURN",
"is_entry": true,
"is_exit": false,
"quantity": 6.1281,
"previous_quantity": 435.6484,
"new_quantity": 441.7765,
"reason": "Eaque sequi rerum ut autem.",
"movement_date": "2026-11-26T12:57:09.000000Z",
"created_at": null
},
{
"id": "088dc71e-79e8-3287-85e6-c7ac29ca3452",
"code": "MOV-415823",
"type": "produção",
"type_name": "PRODUCTION",
"is_entry": true,
"is_exit": false,
"quantity": 47.0076,
"previous_quantity": 432.3628,
"new_quantity": 479.3704,
"reason": null,
"movement_date": "2026-11-04T14:54:46.000000Z",
"created_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create movement
requires authentication stock.movement store
Creates a new entry or exit movement in the stock
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/stocks/1/movements" \
--header "Authorization: Bearer 5V3Za4a68dcEe1bvfkhDP6g" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"product_id\": \"98eaefa6-bd6b-30e6-ac95-a27e8a7db6a2\",
\"type\": \"Example Type\",
\"quantity\": 1,
\"reason\": \"Example Reason\",
\"reference_type\": \"Example Reference type\",
\"reference_id\": 1,
\"movement_date\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/1/movements"
);
const headers = {
"Authorization": "Bearer 5V3Za4a68dcEe1bvfkhDP6g",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"product_id": "98eaefa6-bd6b-30e6-ac95-a27e8a7db6a2",
"type": "Example Type",
"quantity": 1,
"reason": "Example Reason",
"reference_type": "Example Reference type",
"reference_id": 1,
"movement_date": "2024-01-01"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "a4378dc4-ee9f-3c33-9df1-1bdd0ecf2007",
"code": "MOV-074845",
"type": "ajuste entrada",
"type_name": "ADJUSTMENT_IN",
"is_entry": true,
"is_exit": false,
"quantity": 47.7889,
"previous_quantity": 696.4348,
"new_quantity": 744.2237,
"reason": null,
"movement_date": "2026-11-03T11:44:09.000000Z",
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Transfer between stocks
requires authentication stock.movement transfer
Transfers products from one stock to another
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/stocks/019556e7-2e9f-777c-a177-30bbf0646c32/movements/transfer" \
--header "Authorization: Bearer 6k5daePf3c48vDgZb16EVha" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"product_id\": \"f154ff59-dfdc-3fb8-85b3-22b7bf5b8b3e\",
\"destination_stock_id\": \"4c5421de-907e-3b97-a73d-25f7d2b7b280\",
\"quantity\": 1,
\"reason\": \"Example Reason\",
\"movement_date\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/019556e7-2e9f-777c-a177-30bbf0646c32/movements/transfer"
);
const headers = {
"Authorization": "Bearer 6k5daePf3c48vDgZb16EVha",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"product_id": "f154ff59-dfdc-3fb8-85b3-22b7bf5b8b3e",
"destination_stock_id": "4c5421de-907e-3b97-a73d-25f7d2b7b280",
"quantity": 1,
"reason": "Example Reason",
"movement_date": "2024-01-01"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "09d6aa3d-11e4-3590-81a0-b52124aa857b",
"code": "MOV-528322",
"type": "perda",
"type_name": "LOSS",
"is_entry": false,
"is_exit": true,
"quantity": 44.6475,
"previous_quantity": 848.0144,
"new_quantity": 803.3669,
"reason": null,
"movement_date": "2026-11-13T18:47:03.000000Z",
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Inventory adjustment
requires authentication stock.movement inventory
Performs inventory adjustment to correct stock quantity
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/stocks/019556e7-2e9f-777c-a177-30bbf0646c32/movements/inventory" \
--header "Authorization: Bearer hvDVd6Zc6P54e8E1kbafg3a" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"product_id\": \"a9c9a758-3a32-3349-83f3-f5564a91d2b9\",
\"new_quantity\": 1,
\"reason\": \"Example Reason\",
\"movement_date\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stocks/019556e7-2e9f-777c-a177-30bbf0646c32/movements/inventory"
);
const headers = {
"Authorization": "Bearer hvDVd6Zc6P54e8E1kbafg3a",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"product_id": "a9c9a758-3a32-3349-83f3-f5564a91d2b9",
"new_quantity": 1,
"reason": "Example Reason",
"movement_date": "2024-01-01"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "9ba5a8ad-21ea-31f3-8bbc-64e518c591d9",
"code": "MOV-829411",
"type": "ajuste saída",
"type_name": "ADJUSTMENT_OUT",
"is_entry": false,
"is_exit": true,
"quantity": 37.1507,
"previous_quantity": 17.146,
"new_quantity": 0,
"reason": "Voluptatem qui distinctio possimus voluptatem suscipit rerum quia.",
"movement_date": "2026-10-28T10:11:48.000000Z",
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Purchase entry
requires authentication stock.movement store
Registers a purchase entry directly into the main stock
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/stock-movements/purchase" \
--header "Authorization: Bearer P6VZevdba6afg3c8154DkhE" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"product_id\": \"100300da-d667-3487-b90e-bf1ad6c29007\",
\"quantity\": 1,
\"reason\": \"Example Reason\",
\"movement_date\": \"2024-01-01\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stock-movements/purchase"
);
const headers = {
"Authorization": "Bearer P6VZevdba6afg3c8154DkhE",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"product_id": "100300da-d667-3487-b90e-bf1ad6c29007",
"quantity": 1,
"reason": "Example Reason",
"movement_date": "2024-01-01"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "b3c4057a-e966-3374-bffa-91d9c6e2bcfc",
"code": "MOV-349564",
"type": "perda",
"type_name": "LOSS",
"is_entry": false,
"is_exit": true,
"quantity": 30.3213,
"previous_quantity": 519.1168,
"new_quantity": 488.7955,
"reason": null,
"movement_date": "2026-11-21T13:07:34.000000Z",
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show movement
requires authentication stock.movement index
Returns details of a specific movement
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/stock-movements/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer aPbachZe1v6Ef3Vdgk4D685" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/stock-movements/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer aPbachZe1v6Ef3Vdgk4D685",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "10c9f9a8-a58f-3d95-b04c-34bd46968ca6",
"code": "MOV-354852",
"type": "perda",
"type_name": "LOSS",
"is_entry": false,
"is_exit": true,
"quantity": 58.3693,
"previous_quantity": 473.0099,
"new_quantity": 414.6406,
"reason": null,
"movement_date": "2026-11-19T06:01:49.000000Z",
"created_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Suppliers
Endpoints for suppliers
List suppliers
requires authentication suppliers index
List all suppliers
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/suppliers?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Supplier+name" \
--header "Authorization: Bearer d3fb8ZP64V5aevg1ackhE6D" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Supplier name",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer d3fb8ZP64V5aevg1ackhE6D",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "688556f0-94f1-3c66-8da3-0c8abe67d812",
"name": "Sr. Aaron Ítalo Zamana Neto",
"email": "flavio.bonilha@example.org",
"phone": "(55) 4716-2347",
"document": "30.676.825/0001-91",
"type": "pj",
"responsible": "Dr. Aaron Flávio Mascarenhas Jr.",
"image": {
"id": null,
"url": null
},
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
}
},
{
"id": "7b43c961-4ee3-35b9-8493-a1aac51a1f38",
"name": "Théo Evandro Rivera Jr.",
"email": "ornela99@example.com",
"phone": "(67) 4264-1855",
"document": "17.410.972/0001-57",
"type": "pj",
"responsible": "Suzana Sofia Assunção",
"image": {
"id": null,
"url": null
},
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
}
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create supplier
requires authentication suppliers store
Create a new supplier
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/suppliers" \
--header "Authorization: Bearer 84e6hgkZVcDbavPEdfa1365" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"email\": \"user@example.com\",
\"phone\": \"(11) 99999-9999\",
\"document\": \"Example Document\",
\"type\": \"Example Type\",
\"responsible\": \"Example Responsible\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"name\": \"Example Name\",
\"extension\": \"Example Image extension\",
\"size\": \"Example Image size\"
},
\"address\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"street\": \"Example Address street\",
\"number\": \"Example Address number\",
\"complement\": \"Example Address complement\",
\"neighborhood\": \"Example Address neighborhood\",
\"city\": \"Example Address city\",
\"state\": \"Example Address state\",
\"zip_code\": \"Example Address zip code\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers"
);
const headers = {
"Authorization": "Bearer 84e6hgkZVcDbavPEdfa1365",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"email": "user@example.com",
"phone": "(11) 99999-9999",
"document": "Example Document",
"type": "Example Type",
"responsible": "Example Responsible",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"name": "Example Name",
"extension": "Example Image extension",
"size": "Example Image size"
},
"address": {
"0": "example1",
"1": "example2",
"street": "Example Address street",
"number": "Example Address number",
"complement": "Example Address complement",
"neighborhood": "Example Address neighborhood",
"city": "Example Address city",
"state": "Example Address state",
"zip_code": "Example Address zip code"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get supplier
requires authentication suppliers show
Get a supplier
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/suppliers/1" \
--header "Authorization: Bearer 4Dac8aP16hEfVd5Zk3beg6v" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers/1"
);
const headers = {
"Authorization": "Bearer 4Dac8aP16hEfVd5Zk3beg6v",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "cfce25d6-08a5-3595-98b7-ca12827a8e04",
"name": "Gabrielle Galhardo Rocha Sobrinho",
"email": "pablo29@example.org",
"phone": "(15) 3002-4668",
"document": "55.022.450/0001-77",
"type": "pf",
"responsible": "Srta. Angélica Yasmin Camacho Neto",
"image": {
"id": null,
"url": null
},
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update supplier
requires authentication suppliers update
Update a supplier
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/suppliers/1" \
--header "Authorization: Bearer aVcv8akP5dh4gD6b63ZfeE1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"email\": \"user@example.com\",
\"phone\": \"(11) 99999-9999\",
\"document\": \"Example Document\",
\"type\": \"Example Type\",
\"responsible\": \"Example Responsible\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"name\": \"Example Name\",
\"extension\": \"Example Image extension\",
\"size\": \"Example Image size\"
},
\"address\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"street\": \"Example Address street\",
\"number\": \"Example Address number\",
\"complement\": \"Example Address complement\",
\"neighborhood\": \"Example Address neighborhood\",
\"city\": \"Example Address city\",
\"state\": \"Example Address state\",
\"zip_code\": \"Example Address zip code\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers/1"
);
const headers = {
"Authorization": "Bearer aVcv8akP5dh4gD6b63ZfeE1",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"email": "user@example.com",
"phone": "(11) 99999-9999",
"document": "Example Document",
"type": "Example Type",
"responsible": "Example Responsible",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"name": "Example Name",
"extension": "Example Image extension",
"size": "Example Image size"
},
"address": {
"0": "example1",
"1": "example2",
"street": "Example Address street",
"number": "Example Address number",
"complement": "Example Address complement",
"neighborhood": "Example Address neighborhood",
"city": "Example Address city",
"state": "Example Address state",
"zip_code": "Example Address zip code"
}
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete supplier
requires authentication suppliers delete
Delete a supplier
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/suppliers/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer bk1gd3Ea66ahZPe85f4vcVD" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer bk1gd3Ea66ahZPe85f4vcVD",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List supplier bank accounts
requires authentication suppliers show
Contas e chaves PIX do fornecedor, com a favorita primeiro.
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/suppliers/1/bank-account" \
--header "Authorization: Bearer c3P1dav8DZ6kea5fhg4bEV6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers/1/bank-account"
);
const headers = {
"Authorization": "Bearer c3P1dav8DZ6kea5fhg4bEV6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "a351a0dc-c9fa-4c7f-a3b7-b4b12d4e99f9",
"bank": null,
"agency": null,
"account": null,
"account_type": null,
"pix_key": "balistreri.sonia@hotmail.com",
"favorite": false
},
{
"id": "a351a0dc-cd7c-4b42-b04e-259700ed5ab3",
"bank": null,
"agency": null,
"account": null,
"account_type": null,
"pix_key": "deion.aufderhar@gleichner.net",
"favorite": false
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add supplier bank account
requires authentication suppliers update
Agência e conta são opcionais: o prestador costuma ter só a chave PIX. Marcar como favorita desmarca as outras.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/suppliers/1/bank-account" \
--header "Authorization: Bearer Dcd5v6861f3ZaVgEPehb4ak" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"bank_id\": \"a25cc4cf-5f03-3eed-aee3-0838b855d001\",
\"agency\": \"syddbznzltpxg\",
\"account\": \"ssftxcywdxurncvwfwlgimjkg\",
\"account_type\": \"bknsaxikpvoromdvnrommm\",
\"pix_key\": \"sanqdokehxwhkyurt\",
\"favorite\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers/1/bank-account"
);
const headers = {
"Authorization": "Bearer Dcd5v6861f3ZaVgEPehb4ak",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"bank_id": "a25cc4cf-5f03-3eed-aee3-0838b855d001",
"agency": "syddbznzltpxg",
"account": "ssftxcywdxurncvwfwlgimjkg",
"account_type": "bknsaxikpvoromdvnrommm",
"pix_key": "sanqdokehxwhkyurt",
"favorite": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "a351a0dc-d673-4289-aca7-8f1735de71e3",
"bank": null,
"agency": null,
"account": null,
"account_type": null,
"pix_key": "armando.leannon@hotmail.com",
"favorite": false
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update supplier bank account
requires authentication suppliers update
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/suppliers/1/bank-account/eos" \
--header "Authorization: Bearer bZ15aDgkve6P48hEfa3Vc6d" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"bank_id\": \"dec4a5f9-7232-3dc9-b0e0-48b7b2aa0521\",
\"agency\": \"sfukzumlssblpx\",
\"account\": \"flkhrchbvhtz\",
\"account_type\": \"jdjskkdfjkrwgm\",
\"pix_key\": \"fcpjxmdt\",
\"favorite\": false
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers/1/bank-account/eos"
);
const headers = {
"Authorization": "Bearer bZ15aDgkve6P48hEfa3Vc6d",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"bank_id": "dec4a5f9-7232-3dc9-b0e0-48b7b2aa0521",
"agency": "sfukzumlssblpx",
"account": "flkhrchbvhtz",
"account_type": "jdjskkdfjkrwgm",
"pix_key": "fcpjxmdt",
"favorite": false
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "a351a0dc-e053-46a9-89a6-95a7c4f7cd3c",
"bank": null,
"agency": null,
"account": null,
"account_type": null,
"pix_key": "florine21@gmail.com",
"favorite": false
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete supplier bank account
requires authentication suppliers update
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/suppliers/ab/bank-account/quos" \
--header "Authorization: Bearer bZa8avV1hfP3ck6645EDdeg" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/suppliers/ab/bank-account/quos"
);
const headers = {
"Authorization": "Bearer bZa8avV1hfP3ck6645EDdeg",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "Conta removida com sucesso."
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
System Types
Endpoints for system types
System Types
requires authentication No specific permission required
Get the system types
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/system-types" \
--header "Authorization: Bearer ag6Pb8kDe56V3hv1cZda4Ef" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/system-types"
);
const headers = {
"Authorization": "Bearer ag6Pb8kDe56V3hv1cZda4Ef",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"bankAccountTypes": {
"key": "value"
},
"fileTypes": {
"key": "value"
},
"legalEntityTypes": {
"key": "value"
},
"transactionTypes": {
"key": "value"
}
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Transaction Categories
Endpoints for transaction categories
List transaction categories
requires authentication transaction-category index
List all transaction categories
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/transaction-categories?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Salary&type=entrada" \
--header "Authorization: Bearer aa8edhvcg34k5P6Ef6D1VbZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/transaction-categories"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Salary",
"type": "entrada",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer aa8edhvcg34k5P6Ef6D1VbZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "24b128c2-5031-3d03-a3bf-4316cf3f4d1f",
"name": "Jonas de Freitas Lourenço",
"description": "Perspiciatis in aut laudantium saepe ut reiciendis. Officiis sunt rerum quo rerum veritatis itaque illo quidem. Et sed sit omnis.",
"type": "ajuste saída"
},
{
"id": "df3bfacc-8a59-3a14-b816-c7c78c83c22a",
"name": "Eliane Bezerra Valência",
"description": "Sint aperiam alias beatae. Sit rerum soluta esse dolores aspernatur autem. Consectetur laboriosam voluptates quibusdam tenetur sint.",
"type": "tarifa"
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show transaction category
requires authentication transaction-category show
Show a transaction category
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/transaction-categories/nemo" \
--header "Authorization: Bearer gkVZ4eh6dv8c3651EPfabDa" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/transaction-categories/nemo"
);
const headers = {
"Authorization": "Bearer gkVZ4eh6dv8c3651EPfabDa",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "8f9f2ecf-4986-3d3f-9167-a5eded4e9b76",
"name": "Márcia Valentin Neto",
"description": "Veritatis delectus sint sed eum. Quos aut rerum eos eos. Voluptatem molestiae ex quo dolor nemo ut omnis.",
"type": "pagamento"
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create transaction category
requires authentication transaction-category store
Create a new transaction category
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/transaction-categories" \
--header "Authorization: Bearer 6583P6ZkDbdfa4vEgVhae1c" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"type\": \"Example Type\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/transaction-categories"
);
const headers = {
"Authorization": "Bearer 6583P6ZkDbdfa4vEgVhae1c",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"type": "Example Type"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update transaction category
requires authentication transaction-category update
Update a transaction category
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/transaction-categories/nihil" \
--header "Authorization: Bearer kdc6E5vZbV3hDf48Pea6g1a" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"description\": \"Example Description\",
\"type\": \"Example Type\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/transaction-categories/nihil"
);
const headers = {
"Authorization": "Bearer kdc6E5vZbV3hDf48Pea6g1a",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"description": "Example Description",
"type": "Example Type"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete transaction category
requires authentication transaction-category delete
Delete a transaction category
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/transaction-categories/ad" \
--header "Authorization: Bearer Ev6Z8ck45Dh6f3abPd1Vage" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/transaction-categories/ad"
);
const headers = {
"Authorization": "Bearer Ev6Z8ck45Dh6f3abPd1Vage",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Tutoriais (administração)
Cadastro do catálogo de módulos da Central de Tutoriais
Listar módulos
requires authentication tutorials index
Lista o catálogo de módulos de tutorial
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Financeiro&is_active=1" \
--header "Authorization: Bearer 6avZfacV4g1dbEDe5386kPh" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Financeiro",
"is_active": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 6avZfacV4g1dbEDe5386kPh",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "2c637021-8e46-3227-a794-aeca001c6e6f",
"name": "Adipisci a",
"slug": "adipisci-a-599513",
"description": "Eos tempore ut magnam voluptatem.",
"icon": null,
"color": null,
"sort_order": 0,
"is_active": true,
"created_at": null,
"updated_at": null
},
{
"id": "946e1fe3-867c-3006-96f7-50b79d04e888",
"name": "Et autem",
"slug": "et-autem-312643",
"description": "Iusto eligendi commodi sapiente et voluptas repellat.",
"icon": null,
"color": null,
"sort_order": 0,
"is_active": true,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cadastrar módulo
requires authentication tutorials store
Cria um módulo no catálogo. O slug é derivado do nome quando não informado.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules" \
--header "Authorization: Bearer PgEk36a45c8DhfVZdva6eb1" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"slug\": \"Example Slug\",
\"description\": \"Example Description\",
\"icon\": \"Example Icon\",
\"color\": \"Example Color\",
\"sort_order\": 1,
\"is_active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules"
);
const headers = {
"Authorization": "Bearer PgEk36a45c8DhfVZdva6eb1",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"slug": "Example Slug",
"description": "Example Description",
"icon": "Example Icon",
"color": "Example Color",
"sort_order": 1,
"is_active": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "95cf2b78-7540-3769-9c77-0764602d5ba3",
"name": "Numquam qui",
"slug": "numquam-qui-35954",
"description": "Aut quia neque in.",
"icon": null,
"color": null,
"sort_order": 0,
"is_active": true,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Visualizar módulo
requires authentication tutorials index
Detalhe de um módulo do catálogo
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer 1865kdgEb6PZ4Vhe3acvDaf" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer 1865kdgEb6PZ4Vhe3acvDaf",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "8153bc08-4fd3-368b-8bf7-d3766e55841e",
"name": "Quas earum",
"slug": "quas-earum-392920",
"description": "Sed voluptas distinctio consequatur ut aut et saepe.",
"icon": null,
"color": null,
"sort_order": 0,
"is_active": true,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Atualizar módulo
requires authentication tutorials update
Atualiza um módulo do catálogo
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer kcZEevfa66V43Dhgabd51P8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"slug\": \"Example Slug\",
\"description\": \"Example Description\",
\"icon\": \"Example Icon\",
\"color\": \"Example Color\",
\"sort_order\": 1,
\"is_active\": true
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer kcZEevfa66V43Dhgabd51P8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"slug": "Example Slug",
"description": "Example Description",
"icon": "Example Icon",
"color": "Example Color",
"sort_order": 1,
"is_active": true
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "47954430-6365-3278-b264-0e2459ab83b5",
"name": "Vero inventore",
"slug": "vero-inventore-228651",
"description": "Exercitationem repellat est consequatur sed dolores nemo.",
"icon": null,
"color": null,
"sort_order": 0,
"is_active": true,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remover módulo
requires authentication tutorials destroy
Remove o módulo e, junto, os tutoriais que pertenciam a ele
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer va461d6gVeb3fch8ZkDEaP5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-modules/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer va461d6gVeb3fch8ZkDEaP5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Listar tutoriais
requires authentication tutorials index
Lista os tutoriais em qualquer status, para quem administra
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/admin/tutorials?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=ordem+de+servi%C3%A7o&module_id[]=90b04036-f4e6-3449-99e5-c154cee0b64f&status=published" \
--header "Authorization: Bearer v8caEVe34fgka66hbZDd1P5" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "ordem de serviço",
"module_id[0]": "90b04036-f4e6-3449-99e5-c154cee0b64f",
"status": "published",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer v8caEVe34fgka66hbZDd1P5",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "b2d1ec3c-4d13-3efe-a04a-58aa4af0b527",
"title": "Inventore qui dolores non",
"description": "Et et cupiditate et atque.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-235e-4e93-8364-5257072ca035",
"name": "Cupiditate minima",
"slug": "cupiditate-minima-386918",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
},
{
"id": "f06bbde4-5930-3f8b-ad59-48cfbd901247",
"title": "Magnam dolores numquam et",
"description": "Eum omnis sed earum natus.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-2792-45a6-8718-113d65edda4f",
"name": "Eos voluptatum",
"slug": "eos-voluptatum-823901",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Cadastrar tutorial
requires authentication tutorials store
Cria um tutorial. Nasce como rascunho e só aparece na central depois de publicado.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials" \
--header "Authorization: Bearer 1badeacEkPD538Zf6h6v4Vg" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"module_id\": \"44fb2e11-196c-3753-a74d-5601dff98c4f\",
\"title\": \"Example Title\",
\"description\": \"Example Description\",
\"cover_path\": \"Example Cover path\",
\"sort_order\": 1,
\"sectors\": [
\"28258410-c8df-3994-adb2-1878371f6f22\"
],
\"permissions\": [
\"44770118-d690-313f-b2ba-afcc28e331da\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials"
);
const headers = {
"Authorization": "Bearer 1badeacEkPD538Zf6h6v4Vg",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"module_id": "44fb2e11-196c-3753-a74d-5601dff98c4f",
"title": "Example Title",
"description": "Example Description",
"cover_path": "Example Cover path",
"sort_order": 1,
"sectors": [
"28258410-c8df-3994-adb2-1878371f6f22"
],
"permissions": [
"44770118-d690-313f-b2ba-afcc28e331da"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "b7511946-b957-3ba0-8c79-42e3b9fe0145",
"title": "Sint saepe asperiores sed",
"description": "Earum recusandae qui neque dolorem odit a autem.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-314e-48c8-87d8-17c6e77dff14",
"name": "Quisquam doloremque",
"slug": "quisquam-doloremque-400007",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Gerar URL de upload
requires authentication tutorials store
Devolve uma URL assinada de curta validade para o cliente enviar o arquivo direto ao S3. O arquivo só é conferido depois, ao criar o item ou salvar a capa.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/upload-url" \
--header "Authorization: Bearer aPDv6Vdbg3E5kea486fcZ1h" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"kind\": \"Example Kind\",
\"filename\": \"Example Name\",
\"extension\": \"Example Extension\",
\"size_bytes\": 1
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/upload-url"
);
const headers = {
"Authorization": "Bearer aPDv6Vdbg3E5kea486fcZ1h",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"kind": "Example Kind",
"filename": "Example Name",
"extension": "Example Extension",
"size_bytes": 1
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"url": "string",
"headers": "array",
"path": "string",
"expires_in": "integer"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Visualizar tutorial
requires authentication tutorials index
Detalhe do tutorial com vínculos e itens
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/admin/tutorials/1" \
--header "Authorization: Bearer PkcVa1bda56hvDEg364Z8fe" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/1"
);
const headers = {
"Authorization": "Bearer PkcVa1bda56hvDEg364Z8fe",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "fe498060-9a3c-3438-9b6a-6100c063a8fb",
"title": "Similique repellat quasi eveniet",
"description": "Cupiditate consequatur iure aliquam enim.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-3bb1-453e-a2ed-ca403d48ffa2",
"name": "Ex rerum",
"slug": "ex-rerum-398590",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Atualizar tutorial
requires authentication tutorials update
Atualiza o tutorial e os vínculos de setor e permissão
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/1" \
--header "Authorization: Bearer f8Vba4Dcav3g1ed65EZP6kh" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"module_id\": \"93bb5743-faa6-33cd-b25d-3221fcee13f2\",
\"title\": \"Example Title\",
\"description\": \"Example Description\",
\"cover_path\": \"Example Cover path\",
\"sort_order\": 1,
\"sectors\": [
\"3b2f0192-f7b3-3a46-be45-bf9928e43d59\"
],
\"permissions\": [
\"d363184b-d579-3bd8-8ede-ed8f78d359f5\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/1"
);
const headers = {
"Authorization": "Bearer f8Vba4Dcav3g1ed65EZP6kh",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"module_id": "93bb5743-faa6-33cd-b25d-3221fcee13f2",
"title": "Example Title",
"description": "Example Description",
"cover_path": "Example Cover path",
"sort_order": 1,
"sectors": [
"3b2f0192-f7b3-3a46-be45-bf9928e43d59"
],
"permissions": [
"d363184b-d579-3bd8-8ede-ed8f78d359f5"
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "471a5dba-9e91-38ed-afb6-2652ccd2b3f7",
"title": "Quod mollitia eveniet rerum",
"description": "Saepe labore vel aperiam voluptatem consequuntur quo alias.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-44a9-4ebc-9a10-6714f046a841",
"name": "Reprehenderit ducimus",
"slug": "reprehenderit-ducimus-702023",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remover tutorial
requires authentication tutorials destroy
Remove o tutorial, os itens e os arquivos correspondentes no S3
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/1" \
--header "Authorization: Bearer 6akegEPvaV6hf538bcZD1d4" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/1"
);
const headers = {
"Authorization": "Bearer 6akegEPvaV6hf538bcZD1d4",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Publicar tutorial
requires authentication tutorials update
Publica o tutorial e carimba a data de publicação
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/019556e7-2e9f-777c-a177-30bbf0646c32/publish" \
--header "Authorization: Bearer ePhED58vcV3g4fk6a16dZba" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/019556e7-2e9f-777c-a177-30bbf0646c32/publish"
);
const headers = {
"Authorization": "Bearer ePhED58vcV3g4fk6a16dZba",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "8dabee70-efb1-3718-ae41-d2f267ee6c6e",
"title": "Corrupti natus autem sunt",
"description": "Ducimus nulla molestiae quaerat nihil qui alias qui.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-4d2f-45d8-a6a3-cdfea2d75054",
"name": "Eum amet",
"slug": "eum-amet-974190",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Despublicar tutorial
requires authentication tutorials update
Devolve o tutorial ao rascunho e limpa a data de publicação
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/019556e7-2e9f-777c-a177-30bbf0646c32/unpublish" \
--header "Authorization: Bearer V3d6vaZ5E1keDbcg68aPf4h" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/019556e7-2e9f-777c-a177-30bbf0646c32/unpublish"
);
const headers = {
"Authorization": "Bearer V3d6vaZ5E1keDbcg68aPf4h",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "9a4fefa7-e28e-36bd-bdfb-03b737786071",
"title": "Aperiam tenetur nam enim",
"description": "Iure nobis aut velit cum earum hic.",
"cover_url": null,
"status": "draft",
"published_at": null,
"sort_order": 0,
"module": {
"id": "a351a0dd-520a-476c-ba1a-371a4097ea6d",
"name": "Quia et",
"slug": "quia-et-502665",
"icon": null,
"color": null
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Adicionar item ao tutorial
requires authentication tutorials store
Cria o item a partir de um arquivo já enviado ao S3 (pdf ou video) ou de um link do YouTube/Vimeo. O arquivo é conferido aqui: existência, tamanho real e assinatura do conteúdo.
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/1/items" \
--header "Authorization: Bearer aVg4Ze6bfha1kvP3dcDE856" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"type\": \"Example Type\",
\"title\": \"Example Title\",
\"file_path\": \"Example File path\",
\"external_url\": \"https:\\/\\/example.com\",
\"duration_seconds\": 1,
\"sort_order\": 1
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/1/items"
);
const headers = {
"Authorization": "Bearer aVg4Ze6bfha1kvP3dcDE856",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"type": "Example Type",
"title": "Example Title",
"file_path": "Example File path",
"external_url": "https:\/\/example.com",
"duration_seconds": 1,
"sort_order": 1
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"data": {
"id": "55e15155-3a19-351a-9da7-1179f687f876",
"type": "pdf",
"title": "Possimus quaerat ea",
"mime_type": "application/pdf",
"size_bytes": 745827,
"duration_seconds": null,
"sort_order": 0,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Reordenar itens
requires authentication tutorials update
Grava a ordem dos itens conforme a sequência de UUIDs enviada
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/019556e7-2e9f-777c-a177-30bbf0646c32/items/reorder" \
--header "Authorization: Bearer Pf3V6ab1hZ5agv6e4kDEc8d" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"items\": [
\"33875d7a-aaa0-3ccc-a15e-4e6028094b94\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorials/019556e7-2e9f-777c-a177-30bbf0646c32/items/reorder"
);
const headers = {
"Authorization": "Bearer Pf3V6ab1hZ5agv6e4kDEc8d",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"items": [
"33875d7a-aaa0-3ccc-a15e-4e6028094b94"
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Itens reordenados com sucesso"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Atualizar item
requires authentication tutorials update
Atualiza o item. O tipo não muda depois de criado.
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-items/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer 86DkaPb64vafV5Eg1c3eZdh" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"Example Title\",
\"file_path\": \"Example File path\",
\"external_url\": \"https:\\/\\/example.com\",
\"duration_seconds\": 1,
\"sort_order\": 1
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-items/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer 86DkaPb64vafV5Eg1c3eZdh",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "Example Title",
"file_path": "Example File path",
"external_url": "https:\/\/example.com",
"duration_seconds": 1,
"sort_order": 1
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"data": {
"id": "1d52abe3-07c9-3446-b8fe-238e4925086b",
"type": "pdf",
"title": "Et ab cumque",
"mime_type": "application/pdf",
"size_bytes": 3876950,
"duration_seconds": null,
"sort_order": 0,
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remover item
requires authentication tutorials destroy
Remove o item e apaga o arquivo correspondente no S3
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-items/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer 8aD5Pkgc1edhb3v664aVZfE" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/admin/tutorial-items/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer 8aD5Pkgc1edhb3v664aVZfE",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Units
Endpoints for units
List units
requires authentication unit index
List all units
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/units?q=Structure" \
--header "Authorization: Bearer a5bPZEcg6d8kV4vDa31fe6h" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/units"
);
const params = {
"q": "Structure",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer a5bPZEcg6d8kV4vDa31fe6h",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "7aaee972-2b31-3155-aa6f-3cdb7a257b29",
"name": "Dr. Daniele de Arruda Matos",
"abbreviation": "Dr. Lidiane Caroline Santacruz Sobrinho",
"description": "Cum minus ut eligendi.",
"created_at": null,
"updated_at": null
},
{
"id": "5d0fd185-3757-3690-b31b-78ca422ec39e",
"name": "Thales Sandoval Maia Neto",
"abbreviation": "Sr. George Vasques Amaral",
"description": "Atque alias odit fugit amet.",
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Show unit
requires authentication unit show
Show a unit
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/units/1" \
--header "Authorization: Bearer Z5abdv81fahDkVPEge463c6" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/units/1"
);
const headers = {
"Authorization": "Bearer Z5abdv81fahDkVPEge463c6",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "b6e76eb7-12be-3729-a7e5-e4bfabc1895f",
"name": "Paulina Assunção Beltrão Neto",
"abbreviation": "Leandro Martines Sobrinho",
"description": "Enim omnis natus et qui.",
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create unit
requires authentication unit store
Create a new unit
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/units" \
--header "Authorization: Bearer dZV6PEhacgbDa53f46e1vk8" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"abbreviation\": \"Example Abbreviation\",
\"description\": \"Example Description\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/units"
);
const headers = {
"Authorization": "Bearer dZV6PEhacgbDa53f46e1vk8",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"abbreviation": "Example Abbreviation",
"description": "Example Description"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update unit
requires authentication unit update
Update a unit
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/units/1" \
--header "Authorization: Bearer 36vP1fchDkd584EZbgaeV6a" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"abbreviation\": \"Example Abbreviation\",
\"description\": \"Example Description\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/units/1"
);
const headers = {
"Authorization": "Bearer 36vP1fchDkd584EZbgaeV6a",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"abbreviation": "Example Abbreviation",
"description": "Example Description"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete unit
requires authentication unit delete
Delete a unit
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/units/aut" \
--header "Authorization: Bearer 4a5vadgDhPE8b663Zekf1Vc" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/units/aut"
);
const headers = {
"Authorization": "Bearer 4a5vadgDhPE8b663Zekf1Vc",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Users
Endpoints for users
List users
requires authentication user index
List all users
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/users?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=John+Doe§or_id=123e4567-e89b-12d3-a456-426614174000&role=ADMIN" \
--header "Authorization: Bearer 1c86fEZgDke4d65aabhV3Pv" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/users"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "John Doe",
"sector_id": "123e4567-e89b-12d3-a456-426614174000",
"role": "ADMIN",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer 1c86fEZgDke4d65aabhV3Pv",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "76faebc3-67ed-311f-8bd6-0c3ebe070c71",
"name": "Nathan Heathcote",
"username": "xthiel",
"email": "tnicolas@example.net",
"certification": null,
"crea": null,
"last_login_at": null,
"image": {
"id": null,
"url": null
},
"sectors": [],
"roles": []
},
{
"id": "99fe7caf-2176-3523-8ef0-daaeab35d023",
"name": "Brady Schimmel",
"username": "santa.prosacco",
"email": "katlyn76@example.com",
"certification": null,
"crea": null,
"last_login_at": null,
"image": {
"id": null,
"url": null
},
"sectors": [],
"roles": []
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get user
requires authentication user show
Get a user
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/users/1" \
--header "Authorization: Bearer 46VvDE6gk1fca8d3aZehP5b" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/users/1"
);
const headers = {
"Authorization": "Bearer 46VvDE6gk1fca8d3aZehP5b",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "3fdb5092-2c67-3f2f-9839-ccbfcdb98ecf",
"name": "Dr. Stacey Pacocha DVM",
"username": "rippin.otis",
"email": "roberts.neil@example.com",
"certification": null,
"crea": null,
"last_login_at": null,
"image": {
"id": null,
"url": null
},
"sectors": [],
"roles": []
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create user
requires authentication user store
Create a new user
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/users" \
--header "Authorization: Bearer k86gvebPdEaVhc143fDZ65a" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"certification\": \"Example Certification\",
\"crea\": \"Example Crea\",
\"email\": \"user@example.com\",
\"username\": \"ashlee.kreiger\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"name\": \"Example Name\",
\"extension\": \"Example Image extension\",
\"size\": \"Example Image size\"
},
\"sectors\": [
\"66afb11b-7b18-3c90-88bf-bdf784621424\"
],
\"roles\": [
\"70c03dbc-d51a-35c9-8608-9f5c0cd6ecd7\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/users"
);
const headers = {
"Authorization": "Bearer k86gvebPdEaVhc143fDZ65a",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"certification": "Example Certification",
"crea": "Example Crea",
"email": "user@example.com",
"username": "ashlee.kreiger",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"name": "Example Name",
"extension": "Example Image extension",
"size": "Example Image size"
},
"sectors": [
"66afb11b-7b18-3c90-88bf-bdf784621424"
],
"roles": [
"70c03dbc-d51a-35c9-8608-9f5c0cd6ecd7"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update user
requires authentication user update
Update a user
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/users/1" \
--header "Authorization: Bearer dD5ae8V6fhv4Z6E1bPc3gka" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"certification\": \"Example Certification\",
\"crea\": \"Example Crea\",
\"email\": \"user@example.com\",
\"username\": \"amari.fisher\",
\"password\": \"password123\",
\"image\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"path\": \"Example Image path\",
\"name\": \"Example Name\",
\"extension\": \"Example Image extension\",
\"size\": \"Example Image size\"
},
\"sectors\": [
\"19a5a758-1e5a-3081-bc92-5f834fe1cd6a\"
],
\"roles\": [
\"1f12235d-c43e-3867-aa3d-ebe72a1fb768\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/users/1"
);
const headers = {
"Authorization": "Bearer dD5ae8V6fhv4Z6E1bPc3gka",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"certification": "Example Certification",
"crea": "Example Crea",
"email": "user@example.com",
"username": "amari.fisher",
"password": "password123",
"image": {
"0": "example1",
"1": "example2",
"path": "Example Image path",
"name": "Example Name",
"extension": "Example Image extension",
"size": "Example Image size"
},
"sectors": [
"19a5a758-1e5a-3081-bc92-5f834fe1cd6a"
],
"roles": [
"1f12235d-c43e-3867-aa3d-ebe72a1fb768"
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete user
requires authentication user delete
Delete a user
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/users/1" \
--header "Authorization: Bearer da8DP1che4kEbag6v35fZ6V" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/users/1"
);
const headers = {
"Authorization": "Bearer da8DP1che4kEbag6v35fZ6V",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Reset user password
requires authentication user password-reset
Reset a user password
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/users/019556e7-2e9f-777c-a177-30bbf0646c32/password-reset" \
--header "Authorization: Bearer gVEvh4db3k5PD66feZaa81c" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/users/019556e7-2e9f-777c-a177-30bbf0646c32/password-reset"
);
const headers = {
"Authorization": "Bearer gVEvh4db3k5PD66feZaa81c",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "PUT",
headers,
}).then(response => response.json());Example response (200):
{
"message": "Password reset successfully to foobaar"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Attach permissions to user
requires authentication user update
Attach direct permissions to a user
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/users/1/permissions" \
--header "Authorization: Bearer kav6DeVcE318b6agf5ZdP4h" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"permissions\": [
\"e79c6960-4b68-35d9-844a-a80b836a37d1\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/users/1/permissions"
);
const headers = {
"Authorization": "Bearer kav6DeVcE318b6agf5ZdP4h",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"permissions": [
"e79c6960-4b68-35d9-844a-a80b836a37d1"
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Permissions attached successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List user direct permissions
requires authentication user show
List direct permissions associated with a user
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/users/1/permissions" \
--header "Authorization: Bearer 1vf4Pab6g3D6eZEcahV58dk" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/users/1/permissions"
);
const headers = {
"Authorization": "Bearer 1vf4Pab6g3D6eZEcahV58dk",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": null,
"name": "totam",
"display_name": "Iure quod eum ea temporibus dolorum molestiae qui."
},
{
"id": null,
"name": "perferendis",
"display_name": "Minima et error tenetur."
}
]
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Work Locations
Endpoints for work locations
List work locations
requires authentication work-location index
List all work locations
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/work-locations?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Tecnologia&work=uuid" \
--header "Authorization: Bearer P4a6EgcbDa1V6k5e38fvdhZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/work-locations"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Tecnologia",
"work": "uuid",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer P4a6EgcbDa1V6k5e38fvdhZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "93db25fd-61e2-3853-a56f-f0a111159cad",
"description": "Jean Rivera",
"work": {
"id": null,
"name": null
},
"documents": [],
"created_at": null,
"updated_at": null
},
{
"id": "bd49708d-eeac-3c4e-aff7-12ea9f097bb8",
"description": "Fernando Lira Jr.",
"work": {
"id": null,
"name": null
},
"documents": [],
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create work location
requires authentication work-location store
Create a new work location
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/work-locations" \
--header "Authorization: Bearer 84v65dbf1aEkePc3ZgVha6D" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"description\": \"Example Description\",
\"work_id\": \"38f8efdb-d215-386a-b02a-b5f150280c69\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/work-locations"
);
const headers = {
"Authorization": "Bearer 84v65dbf1aEkePc3ZgVha6D",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"description": "Example Description",
"work_id": "38f8efdb-d215-386a-b02a-b5f150280c69"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get work location
requires authentication work-location show
Get a work location
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/work-locations/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer vg8Vhf6D4dE3aac1P6k5beZ" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/work-locations/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer vg8Vhf6D4dE3aac1P6k5beZ",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "262b05e2-e251-3738-8f9f-197f04d3d6d0",
"description": "Bianca Martines Santana",
"work": {
"id": null,
"name": null
},
"documents": [],
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update work location
requires authentication work-location update
Update a work location
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/work-locations/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer Zk6E1cVaD4bvae5Pfdgh836" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"description\": \"Example Description\",
\"work_id\": \"9b593349-7698-337d-93ec-cf2a9e42a132\"
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/work-locations/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer Zk6E1cVaD4bvae5Pfdgh836",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"description": "Example Description",
"work_id": "9b593349-7698-337d-93ec-cf2a9e42a132"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete work location
requires authentication work-location delete
Delete a work location
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/work-locations/019556e7-2e9f-777c-a177-30bbf0646c32" \
--header "Authorization: Bearer dkcPv3gVebDE1564afa8h6Z" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/work-locations/019556e7-2e9f-777c-a177-30bbf0646c32"
);
const headers = {
"Authorization": "Bearer dkcPv3gVebDE1564afa8h6Z",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Works
Endpoints for works
List works
requires authentication work index
List all works
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/works?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=Tecnologia&customer_id=019556e7-2e9f-777c-a177-30bbf0646c32&status_id=019556e7-2e9f-777c-a177-30bbf0646c32&responsible_id=019556e7-2e9f-777c-a177-30bbf0646c32&no_responsible=1" \
--header "Authorization: Bearer h5c8ak4e1vafDEdb3VPgZ66" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "Tecnologia",
"customer_id": "019556e7-2e9f-777c-a177-30bbf0646c32",
"status_id": "019556e7-2e9f-777c-a177-30bbf0646c32",
"responsible_id": "019556e7-2e9f-777c-a177-30bbf0646c32",
"no_responsible": "1",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer h5c8ak4e1vafDEdb3VPgZ66",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "0dc1ad3e-82dd-3427-9ad0-59420cbe43a7",
"name": "Srta. Alícia Estrada Chaves Sobrinho",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"documents": [],
"locations": [],
"product_quantity_lists_count": 0,
"product_quantity_list_items_count": 0,
"product_requests_count": 0,
"product_request_items_count": 0,
"documents_count": 0,
"locations_documents_count": 0,
"total_documents_count": 0,
"daily_logs_count": 0,
"projects_count": 0,
"started_at": {
"date": "2026-02-04 22:19:30.000000",
"timezone_type": 3,
"timezone": "America/Sao_Paulo"
},
"created_at": null,
"updated_at": null
},
{
"id": "3f4574c5-48cd-3d0c-9f45-8b9b0b08b773",
"name": "Maísa Marques",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"documents": [],
"locations": [],
"product_quantity_lists_count": 0,
"product_quantity_list_items_count": 0,
"product_requests_count": 0,
"product_request_items_count": 0,
"documents_count": 0,
"locations_documents_count": 0,
"total_documents_count": 0,
"daily_logs_count": 0,
"projects_count": 0,
"started_at": {
"date": "2007-02-28 10:02:14.000000",
"timezone_type": 3,
"timezone": "America/Sao_Paulo"
},
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Create work
requires authentication work store
Create a new work
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/works" \
--header "Authorization: Bearer DZdf4aV1g6ka58hc3Eev6Pb" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"customer_id\": \"86a7f413-307b-394d-bd2f-839c1e2ce8dd\",
\"status_id\": \"f4c38f71-8eaf-37af-a931-1ab77ec77a04\",
\"started_at\": \"Example Started at\",
\"address\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"street\": \"Example Address street\",
\"number\": \"Example Address number\",
\"complement\": \"Example Address complement\",
\"neighborhood\": \"Example Address neighborhood\",
\"city\": \"Example Address city\",
\"state\": \"Example Address state\",
\"zip_code\": \"Example Address zip code\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works"
);
const headers = {
"Authorization": "Bearer DZdf4aV1g6ka58hc3Eev6Pb",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"customer_id": "86a7f413-307b-394d-bd2f-839c1e2ce8dd",
"status_id": "f4c38f71-8eaf-37af-a931-1ab77ec77a04",
"started_at": "Example Started at",
"address": {
"0": "example1",
"1": "example2",
"street": "Example Address street",
"number": "Example Address number",
"complement": "Example Address complement",
"neighborhood": "Example Address neighborhood",
"city": "Example Address city",
"state": "Example Address state",
"zip_code": "Example Address zip code"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (201):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get work
requires authentication work show
Get a work
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/works/1" \
--header "Authorization: Bearer cb5v4dkDaZg3Va6Ee68P1fh" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works/1"
);
const headers = {
"Authorization": "Bearer cb5v4dkDaZg3Va6Ee68P1fh",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"id": "4c4d7f7d-9853-3e38-a029-31f1d9a61de4",
"name": "Carla Serra",
"address": {
"street": null,
"number": null,
"complement": null,
"neighborhood": null,
"city": null,
"state": null,
"zip_code": null
},
"documents": [],
"locations": [],
"product_quantity_lists_count": 0,
"product_quantity_list_items_count": 0,
"product_requests_count": 0,
"product_request_items_count": 0,
"documents_count": 0,
"locations_documents_count": 0,
"total_documents_count": 0,
"daily_logs_count": 0,
"projects_count": 0,
"started_at": {
"date": "2006-09-10 16:45:23.000000",
"timezone_type": 3,
"timezone": "America/Sao_Paulo"
},
"created_at": null,
"updated_at": null
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update work
requires authentication work update
Update a work
Example request:
curl --request PUT \
"https://api.bs-homolog.pensou.app.br/api/works/1" \
--header "Authorization: Bearer 4VeDvdgc5hEP1k368aZfab6" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Example Name\",
\"customer_id\": \"b64e64af-2442-33ed-885c-d95ffd41f7bb\",
\"status_id\": \"58e3bae2-ddc1-34c8-b07a-642658d4de63\",
\"started_at\": \"Example Started at\",
\"address\": {
\"0\": \"example1\",
\"1\": \"example2\",
\"street\": \"Example Address street\",
\"number\": \"Example Address number\",
\"complement\": \"Example Address complement\",
\"neighborhood\": \"Example Address neighborhood\",
\"city\": \"Example Address city\",
\"state\": \"Example Address state\",
\"zip_code\": \"Example Address zip code\"
}
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works/1"
);
const headers = {
"Authorization": "Bearer 4VeDvdgc5hEP1k368aZfab6",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Example Name",
"customer_id": "b64e64af-2442-33ed-885c-d95ffd41f7bb",
"status_id": "58e3bae2-ddc1-34c8-b07a-642658d4de63",
"started_at": "Example Started at",
"address": {
"0": "example1",
"1": "example2",
"street": "Example Address street",
"number": "Example Address number",
"complement": "Example Address complement",
"neighborhood": "Example Address neighborhood",
"city": "Example Address city",
"state": "Example Address state",
"zip_code": "Example Address zip code"
}
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "string"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Delete work
requires authentication work delete
Delete a work
Example request:
curl --request DELETE \
"https://api.bs-homolog.pensou.app.br/api/works/1" \
--header "Authorization: Bearer bEDdk86V4a3hvZc1ea5f6gP" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works/1"
);
const headers = {
"Authorization": "Bearer bEDdk86V4a3hvZc1ea5f6gP",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Example response (204):
Empty response
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
List work responsibles
requires authentication work-responsibles index
List all users responsible for a work
Example request:
curl --request GET \
--get "https://api.bs-homolog.pensou.app.br/api/works/019556e7-2e9f-777c-a177-30bbf0646c32/responsibles?sort_by=created_at&sort_desc=1&page=1&per_page=15&q=John" \
--header "Authorization: Bearer hcED356vkbe4a168aZgdPfV" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works/019556e7-2e9f-777c-a177-30bbf0646c32/responsibles"
);
const params = {
"sort_by": "created_at",
"sort_desc": "1",
"page": "1",
"per_page": "15",
"q": "John",
};
Object.keys(params)
.forEach(key => url.searchParams.append(key, params[key]));
const headers = {
"Authorization": "Bearer hcED356vkbe4a168aZgdPfV",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": [
{
"id": "8b3ad4e3-ea4f-39d3-93dc-39ce764320f7",
"name": "Jefferey Prohaska",
"username": "sanford.manuel",
"email": "pharvey@example.net",
"certification": null,
"crea": null,
"last_login_at": null,
"image": {
"id": null,
"url": null
},
"sectors": [],
"roles": []
},
{
"id": "96042031-e79b-3b37-9cf9-ae82e5819f7f",
"name": "Emelie Kutch",
"username": "devon33",
"email": "gertrude30@example.org",
"certification": null,
"crea": null,
"last_login_at": null,
"image": {
"id": null,
"url": null
},
"sectors": [],
"roles": []
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Anterior",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Próximo »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Attach responsibles to work
requires authentication work-responsibles attach
Attach users as responsibles to a work without removing existing ones
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/works/019556e7-2e9f-777c-a177-30bbf0646c32/responsibles/attach" \
--header "Authorization: Bearer DvVEb6fh4aPc31586degZak" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"users\": [
\"8df7a782-5a50-3d26-8f66-8a99c5032eee\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works/019556e7-2e9f-777c-a177-30bbf0646c32/responsibles/attach"
);
const headers = {
"Authorization": "Bearer DvVEb6fh4aPc31586degZak",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"users": [
"8df7a782-5a50-3d26-8f66-8a99c5032eee"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Responsibles attached successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Detach responsibles from work
requires authentication work-responsibles detach
Remove specific users as responsibles from a work
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/works/019556e7-2e9f-777c-a177-30bbf0646c32/responsibles/detach" \
--header "Authorization: Bearer 6abZe5dv6Vha43DPfcEgk18" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"users\": [
\"0eef5830-576a-3f63-bf22-dba79d36f0af\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works/019556e7-2e9f-777c-a177-30bbf0646c32/responsibles/detach"
);
const headers = {
"Authorization": "Bearer 6abZe5dv6Vha43DPfcEgk18",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"users": [
"0eef5830-576a-3f63-bf22-dba79d36f0af"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Responsibles detached successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Sync work responsibles
requires authentication work-responsibles sync
Replace all responsibles of a work with the provided list
Example request:
curl --request POST \
"https://api.bs-homolog.pensou.app.br/api/works/019556e7-2e9f-777c-a177-30bbf0646c32/responsibles/sync" \
--header "Authorization: Bearer fD8V64bka6g53deZhP1vcEa" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"users\": [
\"91dc0d11-f9a4-3354-aac0-98f894373b4b\"
]
}"
const url = new URL(
"https://api.bs-homolog.pensou.app.br/api/works/019556e7-2e9f-777c-a177-30bbf0646c32/responsibles/sync"
);
const headers = {
"Authorization": "Bearer fD8V64bka6g53deZhP1vcEa",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"users": [
"91dc0d11-f9a4-3354-aac0-98f894373b4b"
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Responsibles synchronized successfully"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.