Many MachShip API operations require a company ID. This guide explains how to locate your company ID through the MachShip interface, or the API.
For example, if the URL is:
https://live.machship.com/companies/edit/123456
Then 123456
is your company ID.
To get a list of the company ids in your organisation, you can hit the following endpoint:
GET https://live.machship.com/apiv2/companies/getAll
Note, this endpoint requires certain permissions to be accessible.
{
{
"object": [
{
"id": 12345,
"name": "Big Company Co (Big Co)",
"accountCode": "BIG_CO",
"displayName": "Big Company Co",
"parentCompanyId": 0
}
],
"errors": [
{
"memberNames": [
"string"
],
"errorMessage": "string",
"validationType": 0
}
]
}
}