Skip to content

This page is available as Markdown at https://developers.klaviyo.com/en/v2023-10-15/reference/spawn_create_categories_job.md. An index of every page is at https://developers.klaviyo.com/llms.txt.

KlaviyoKlaviyoDevelopers
v2023-10-15

You're reading the reference for API revision 2023-10-15. The latest revision is 2026-10-15. See this page in the latest revision.

Spawn Create Categories Job

POSThttps://a.klaviyo.com/api/catalog-category-bulk-create-jobs/

Create a catalog category bulk create job to create a batch of catalog categories.

Accepts up to 100 catalog categories per request. The maximum allowed payload size is 4MB.

Revision header
revision: 2023-10-15required
Scopes
catalogs:write
Rate limits
Burst: 75/sSteady: 700/m

Headers

  • revision#stringrequired

    API endpoint revision (format: YYYY-MM-DD[.suffix])

    2023-10-15

Request body

Content type: application/jsonrequired

  • data#objectrequired
    Show 2 fields
    • type#stringrequired
      Allowed values:
      • catalog-category-bulk-create-job
    • attributes#objectrequired
      Show 1 field
      • categories#objectrequired

        Array of catalog categories to create.

        Show 1 field
        • data#object[]required
          Show 3 fields
          • type#stringrequired
            Allowed values:
            • catalog-category
          • attributes#objectrequired
            Show 4 fields
            • external_id#stringrequired

              The ID of the catalog category in an external system.

              Example: SAMPLE-DATA-CATEGORY-APPAREL

            • name#stringrequired

              The name of the catalog category.

              Example: Sample Data Category Apparel

            • integration_type#string

              The integration type. Currently only "$custom" is supported.

              Allowed values:
              • $custom

              Default: $custom

              Example: $custom

            • catalog_type#string

              The type of catalog. Currently only "$default" is supported.

              Default: $default

              Example: $default

          • relationships#object
            Show 1 field
            • items#object
              Show 1 field
              • data#object[]required
                Show 2 fields
                • type#stringrequired
                  Allowed values:
                  • catalog-item
                • id#stringrequired

                  A list of catalog item IDs that are in the given category.

                  Example: $custom:::$default:::SAMPLE-DATA-ITEM-1

Responses

202Success

Content type: application/json

  • data#objectrequired
    Show 4 fields
    • type#stringrequired
      Allowed values:
      • catalog-category-bulk-create-job
    • attributes#objectrequired
      Show 9 fields
      • job_id#stringrequired

        Unique identifier for retrieving the job. Generated by Klaviyo.

      • status#stringrequired

        Status of the asynchronous job.

        Allowed values:
        • cancelled
        • complete
        • processing
        • queued

        Example: processing

      • created_at#string<date-time>required

        The date and time the job was created in ISO 8601 format (YYYY-MM-DDTHH:MM:SS.mmmmmm).

        Example: 2022-11-08T00:00:00

      • total_count#integerrequired

        The total number of operations to be processed by the job. See completed_count for the job's current progress.

        Example: 10

      • completed_count#integer

        The total number of operations that have been completed by the job.

        Default: 0

        Example: 9

      • failed_count#integer

        The total number of operations that have failed as part of the job.

        Default: 0

        Example: 1

      • completed_at#string<date-time>

        Date and time the job was completed in ISO 8601 format (YYYY-MM-DDTHH:MM:SS.mmmmmm).

        Example: 2022-11-08T00:00:00

      • errors#object[]

        Array of errors encountered during the processing of the job.

        Show 5 fields
        • id#stringrequired

          Unique identifier for the error.

          Example: e4eebb08-b055-4a6f-bb13-c8cb69c9eb94

        • code#stringrequired

          A code for classifying the error type.

          Example: invalid

        • title#stringrequired

          A high-level message about the error.

          Example: Invalid input

        • detail#stringrequired

          Specific details about the error.

          Example: The payload provided in the request is invalid.

        • source#objectrequired
          Show 1 field
          • pointer#stringrequired

            A pointer to the source of the error in the request payload.

            Default: /data

            Example: /data

      • expires_at#string<date-time>

        Date and time the job expires in ISO 8601 format (YYYY-MM-DDTHH:MM:SS.mmmmmm).

        Example: 2022-11-08T00:00:00

    • relationships#object
      Show 1 field
      • categories#object
        Show 2 fields
        • data#object[]required
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • catalog-category
          • id#stringrequired

            IDs of the created catalog categories.

            Example: $custom:::$default:::SAMPLE-DATA-CATEGORY-APPAREL

4XXClient Error

Content type: application/json

  • errors#object[]required
    Show 5 fields
    • id#stringrequired
    • code#stringrequired
    • title#stringrequired
    • detail#stringrequired
    • source#object
      Show 2 fields
      • pointer#string
      • parameter#string

5XXServer Error

Content type: application/json

  • errors#object[]required
    Show 5 fields
    • id#stringrequired
    • code#stringrequired
    • title#stringrequired
    • detail#stringrequired
    • source#object
      Show 2 fields
      • pointer#string
      • parameter#string