explodeBom
Requires permission biddesk:assembly:read.
Explodes a bill-of-materials version with chosen options into its full tree, with every problem found (a missing required choice, a broken rule, a conflicting lookup, a cycle…). At most 5,000 nodes. Requires Bid Desk with engineered products and permission to read assemblies.
Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.
Example:
- GraphQL
- cURL
query ExplodeBom($versionId: ID!) {
explodeBom(versionId: $versionId) {
complete
errors {
code
messageKey
path
}
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "query ExplodeBom($versionId: ID!) {\n explodeBom(versionId: $versionId) {\n complete\n errors {\n code\n messageKey\n path\n }\n }\n}",
"variables": {
"versionId": "id"
}
}
EOF
Variables:
{
"versionId": "id"
}
Response:
{
"data": {
"explodeBom": {
"complete": true,
"errors": [
{
"code": "string",
"messageKey": "string",
"path": "string"
}
]
}
}
}
explodeBom(
selections: JSON
versionId: ID!
): BomExplosion!
Arguments
explodeBom.selections ● JSON scalar
Chosen options: { [versionId]: { [groupKey]: [lineId, …] } }, for the version and any sub-assembly. Omitted means defaults.
explodeBom.versionId ● ID! non-null scalar
The version.
Type
BomExplosion object
A bill-of-materials version exploded with chosen options: the tree and every problem found.