Need to manage API keys, view logs, or check usage?Open the Developer portal →

GraphQL mutations

Write operations on the public schema.

Every mutation on this page is billable and non-idempotent. Each successful call debits credits from the owning account. Wrap calls in your own idempotency layer if you're invoking them from a retry-able workflow.

Pulling a material as a whole isn't a concept — you pull individual properties. On processes there are two separate pulls: batch size (input/output exchanges, via pullProcess) and impact values (characterization-method rows, via pullImpacts). Inputs carry the parent id, mirroring the REST URL paths. Find the row ids on the corresponding queries.

pullProperties

Purchase one or more properties of a material — e.g. carbon content, heating value, net. Each revealed property surfaces its numeric value in every subsequent materials / material / materialProperty response.

Schema

input PullPropertiesInput {
  """Id of the parent material — mirrors REST /materials/:materialId/properties/pull."""
  materialId: ID!

  """
  Property ids to pull (1–500). Each id is a row inside the parent material;
  get them from materials.items[].properties[].id.
  """
  propertyIds: [String!]!
}

type PullPropertiesResult {
  materialId: ID!
  pulledPropertyIds: [String!]!
  creditsDebited: Int
}

Mutation

mutation PullProps($input: PullPropertiesInput!) {
  pullProperties(input: $input) {
    materialId
    pulledPropertyIds
    creditsDebited
  }
}

Variables panel:

{
  "input": {
    "materialId": "8c2a17a4-1234-4d1e-9b21-3a8e2c91c0a1",
    "propertyIds": ["55ada...", "18a58..."]
  }
}

pullProcess

Reveal the batch size (input / output exchanges) of a process for one or more of its reference products. Wraps the same processes/pull-many flow used by the Process pull modal in app.circa.ai. A process can have multiple reference products; you pay separately per (process, referenceProduct) pair.

Schema

input PullProcessInput {
  """Id of the process — mirrors REST /processes/:processId/pull."""
  processId: ID!

  """
  Reference-product ids on the process (1–500). Get the values from
  process.referenceProductId on GET /processes responses.
  """
  referenceProductIds: [String!]!
}

type PullProcessResult {
  processId: ID!
  pulledReferenceProductIds: [String!]!
  "How many (process, referenceProduct) pairs were newly revealed by this call."
  revealedCount: Int!
}

Mutation

mutation PullProcess($input: PullProcessInput!) {
  pullProcess(input: $input) {
    processId
    pulledReferenceProductIds
    revealedCount
  }
}

Variables panel:

{
  "input": {
    "processId": "bfffd26f-aa46-42ab-9069-e07102b06c4d",
    "referenceProductIds": ["f5651ee4-1234-4d1e-9b21-3a8e2c91c0a1"]
  }
}

pullImpacts

Reveal impact values on a process by characterization-method id. For parity with the library data model, the field is named characterizationFactorIds on the wire. Wraps the impacts/pull-multiple flow. Discover the ids on impacts[].characterizationFactorProcessIds from processes — each entry is the literal string "cfId,processId" and should be passed verbatim.

Schema

input PullImpactsInput {
  """Id of the parent process — mirrors REST /processes/:processId/impacts/pull."""
  processId: ID!

  """
  Characterization-method ids (1–500). Each entry is "id,processId"
  (the form returned by characterizationFactorProcessIds); a bare cfId is
  also accepted — the process scope is filled in from processId.
  """
  characterizationFactorIds: [String!]!
}

type PullImpactsResult {
  processId: ID!
  "Always returned in the canonical 'cfId,processId' form, even if you sent bare ids."
  pulledCharacterizationFactorIds: [String!]!
}

Mutation

mutation PullImps($input: PullImpactsInput!) {
  pullImpacts(input: $input) {
    processId
    pulledCharacterizationFactorIds
  }
}

Variables panel:

{
  "input": {
    "processId": "340e4939-6d75-430c-b6c7-1e98d566afdd",
    "characterizationFactorIds": [
      "dbc5a15e-e65f-4834-85a6-b9d9940f0a67,340e4939-6d75-430c-b6c7-1e98d566afdd",
      "d0cd0702-bcfa-4f9b-a2e3-4adfc93ccaff,340e4939-6d75-430c-b6c7-1e98d566afdd"
    ]
  }
}