Materials

View as Markdown

The material catalog.

The material object

A material a design can be printed in, either from the 3DAPI catalog or custom.

Attributes

  • idstring or null

    Unique identifier of a catalog material, prefixed with mat_. Null for a custom material.

  • objectstring

    Names the type of this object. Always material.

  • namestring

    Display name, for example PLA Black. For custom materials, exactly what the seller typed.

  • customboolean

    True for a seller-specified material that is not in the catalog. Custom materials need manual review before production.

  • technologystring or null

    Printing technology. fdm is filament printing, the only one offered today. Null for custom materials.

  • colorstring or null

    Color name as listed in the catalog, for example Black. Null for custom materials.

  • color_hexstring or null

    Reference colour of the filament as #RRGGBB, the colour 3DAPI matches the colours in your 3MF files against (see suggested_materials on a quote). Null for custom materials and catalog materials without a reference colour.

  • filament_typestring or null

    Plastic family in lowercase, for example pla or petg. Null for custom materials and when unknown.

The material object
{
  ,
  ,
  ,
  ,
  ,
  ,
  ,
  
}

List catalog materials

GET/v2/materials

Public: no API key needed.

Credentials
None: the endpoint is public.
For
Designers and Integrators
Operation id
list_materials

Lists every material in the 3DAPI catalog, the materials a design can be printed in. Public: no credentials needed. Use the ids when configuring which materials a design allows.

Query parameters

  • limitinteger

    How many results per page, from 1 to 100.

    Range 1 to 100. Defaults to 20.
  • cursorstring

    Where to continue from: the next_cursor of the previous page. Omit for the first page.

Returns200 OK

A page of catalog materials.

Responses

  • 200

    A page of catalog materials.

  • 400

    The request is invalid. details.errors lists each problem (validation_failed), or an expand[] path is unknown (invalid_expand).

  • 429

    Too many requests (rate_limited): the limit is 120 per minute per IP address. Wait for the number of seconds in the Retry-After header, then retry; details has limit, window_seconds, reset_at and retry_after_seconds.

Errors use the error object.

GET/v2/materials
curl "https://public-api.dapi.digital/v2/materials"
Response
{
  "object": "list",
  "data": [
    {
      "id": "mat_bfP0GSqKoZFrD72H5Os0rc7HV9XP6eQJu",
      "object": "material",
      "name": "PLA Black",
      "custom": false,
      "technology": "fdm",
      "color": "Black",
      "color_hex": "#000000",
      "filament_type": "pla"
    }
  ],
  "has_more": false,
  "next_cursor": null
}

Get a catalog material

GET/v2/materials/{id}

Public: no API key needed.

Credentials
None: the endpoint is public.
For
Designers and Integrators
Operation id
get_material

Returns one catalog material by id. Public: no credentials needed.

Path parameters

  • idstringRequired

    Unique identifier of the material, prefixed with mat_. Treat it as an opaque string: store it and compare it, never parse it.

Returns200 OK

The material. Returns the material object.

Responses

  • 200

    The material.

  • 404

    No catalog material has this id (material_not_found).

  • 429

    Too many requests (rate_limited): the limit is 120 per minute per IP address. Wait for the number of seconds in the Retry-After header, then retry; details has limit, window_seconds, reset_at and retry_after_seconds.

Errors use the error object.

GET/v2/materials/{id}
curl "https://public-api.dapi.digital/v2/materials/mat_bfP0GSqKoZFrD72H5Os0rc7HV9XP6eQJu"
Response
{
  "id": "mat_bfP0GSqKoZFrD72H5Os0rc7HV9XP6eQJu",
  "object": "material",
  "name": "PLA Black",
  "custom": false,
  "technology": "fdm",
  "color": "Black",
  "color_hex": "#000000",
  "filament_type": "pla"
}