Request

Response

    Queries

    bomRelationFromState

    query

    Retrieves a BOMRelation based on the specified BOM relation ID and state.

    Template for Query:

    query GetBomRelationFromState($bomRelationId: ID!, $state: String) {
      bomRelationFromState(bomRelationId: $bomRelationId, state: $state) {
        # BOMRelation Fields
      }
    }
    

    Arguments

    bomRelationId*
    ID! non-null
    The ID of the BOM relation.
    stateThe toComponentState string from a previously queried BOMRelation object.
    * Required

    Possible Returns

    Value TypeDescription
    BOMRelation Represents a parent-child relationship between two components in a Bill of Materials (BOM).


    Examples

    Example 1

    Retrieves BOMRelation based on specified bomRelationId and state which is retrieved with bomRelations query.

    Query:

    query GetBomRelationFromState(
     $bomRelationId: ID!
     $state: String
    
    ) {
    bomRelationFromState(bomRelationId: $bomRelationId, state: $state) {

    id quantity

    Query Variables:

    {
       "bomRelationId": "Ym9tcmVsYXRpb25-OWFiTWNGeEtnaFB5Y3d1TW9hR05pa19MMkN-c01ST1JtWjhCODIyTmpIOG1Bd0ZqWA",
       "state": "c3RhdGV-V09SS0lOR35udWxsfnsicm9vdFN0YXRlIjpudWxsLCJzdGF0ZSI6eyJhbmNlc3RvclNlY29uZGFyeVJlYXNvbiI6bnVsbCwiYW5jZXN0b3JTdHJ1Y3R1cmUiOiJERUZBVUxUIiwiY29tcG9zaXRpb24iOiJXT1JLSU5HIiwiaWQiOiJjSEp2WkhWamRINDVZV0pOWTBaNFMyZG9VSGxqZDNWTmIyRkhUbWxyWDB3eVEzNU1hVEp0UkV4RFIweHJPVFJqU1hKdWFXOU9VWEIyWDJGbllRIiwidGltZSI6bnVsbCwidHlwZSI6IkNPTVBPTkVOVCJ9fQ"
    }
    

    Response:

    {
       "data": {
           "bomRelationFromState": {
               "id": "Ym9tcmVsYXRpb25-OWFiTWNGeEtnaFB5Y3d1TW9hR05pa19MMkN-c01ST1JtWjhCODIyTmpIOG1Bd0ZqWA",
               "quantity": 1
           }
       }
    }
    
    Show More