> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getprimo.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Move a task of the Setup

> Move one task of the company's Setup, as the admin does on the Setup page, and return the Setup as `getCompanySetup` does: `DONE` marks it done, `SKIPPED` skips it, `TODO` restores it, `IN_PROGRESS` starts it. Give the task's `key` and, for a task repeated per item (one Connect per HRIS, Zero-Touch per item), its `item`, both as `getCompanySetup` lists them. The move counts as the admin's own. A task done, or one Primo AI is working on, is refused with 409; a task the Setup does not hold with 404. To tick the tasks whose « Done when » an action just made true, use `checkSetupTasks` instead. Only accessible with a Company API key.

Key: WriteScope: Company


## OpenAPI

````yaml https://api.getprimo.com/openapi.json put /company/setup/tasks/{key}/status
openapi: 3.1.1
info:
  title: Public API - BETA
  description: Read docs on https://docs.getprimo.com/
  version: '1.0'
  contact: {}
servers:
  - url: https://api.getprimo.com
security:
  - apikey: []
tags: []
paths:
  /company/setup/tasks/{key}/status:
    put:
      tags:
        - Company
      summary: Move a task of the Setup
      description: >-
        Move one task of the company's Setup, as the admin does on the Setup
        page, and return the Setup as `getCompanySetup` does: `DONE` marks it
        done, `SKIPPED` skips it, `TODO` restores it, `IN_PROGRESS` starts it.
        Give the task's `key` and, for a task repeated per item (one Connect per
        HRIS, Zero-Touch per item), its `item`, both as `getCompanySetup` lists
        them. The move counts as the admin's own. A task done, or one Primo AI
        is working on, is refused with 409; a task the Setup does not hold with
        404. To tick the tasks whose « Done when » an action just made true, use
        `checkSetupTasks` instead. Only accessible with a Company API key.
      operationId: updateSetupTaskStatus
      parameters:
        - name: key
          required: true
          in: path
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateSetupTaskStatusBody'
      responses:
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UpdateSetupTaskStatus_Output'
components:
  schemas:
    UpdateSetupTaskStatusBody:
      type: object
      properties:
        item:
          description: >-
            Which item of a task repeated per item, as `getCompanySetup` gives
            it (e.g. `payfit`, `apple_business`); null for a task that is not
            repeated
          default: null
          anyOf:
            - type: string
              minLength: 1
            - type: 'null'
        status:
          description: >-
            DONE marks it done, SKIPPED skips it, TODO restores it, IN_PROGRESS
            starts it
          type: string
          enum:
            - TODO
            - IN_PROGRESS
            - DONE
            - SKIPPED
      required:
        - status
    UpdateSetupTaskStatus_Output:
      type: object
      properties:
        started:
          type: boolean
          description: >-
            False when the company has no Setup to show: no onboarding yet, or
            one still a draft
        completedAt:
          description: When the Setup ended; null while a task is open
          anyOf:
            - type: string
              format: date-time
              pattern: >-
                ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
            - type: 'null'
        upNext:
          type: array
          description: The tasks the Setup page shows first, in order
          items:
            type: object
            properties:
              key:
                description: >-
                  The Setup task, e.g. `connect_hris`, `connect_slack`,
                  `set_up_apple_mdm`, `turn_on_sentinelone`,
                  `open_first_country`
                type: string
              item:
                description: >-
                  Which HRIS, platform or vendor, for a task repeated per item
                  (e.g. `payfit`, `apple_business`)
                anyOf:
                  - type: string
                  - type: 'null'
              product:
                description: The section of the Setup page the task belongs to
                type: string
              status:
                type: string
                enum:
                  - TODO
                  - IN_PROGRESS
                  - DONE
                  - SKIPPED
              by:
                description: >-
                  Who moved it: ADMIN, PRIMO_AI, PRIMO, PRIMO_TEAM, or DONE_WHEN
                  when Primo found it done on its own; null when nobody did
                anyOf:
                  - type: string
                  - type: 'null'
              skipReason:
                description: Why Primo AI skipped it, e.g. USES_SLACK, NO_ANDROID_DEVICES
                anyOf:
                  - type: string
                  - type: 'null'
              canStart:
                description: False while it waits for the tasks in `startsAfter`
                type: boolean
              startsAfter:
                type: array
                items:
                  type: string
              doItForMe:
                description: Primo AI can do this task for the company
                type: boolean
              minutes:
                description: How long it takes by hand
                anyOf:
                  - type: integer
                    minimum: -9007199254740991
                    maximum: 9007199254740991
                  - type: 'null'
              helpCenterUrl:
                anyOf:
                  - type: string
                  - type: 'null'
              names:
                description: >-
                  What Primo knows the task is about: the HRIS (`hris`), the
                  MDMs left (`mdms`), the admins, a country
                type: object
                propertyNames:
                  type: string
                additionalProperties:
                  anyOf:
                    - type: string
                    - type: array
                      items:
                        type: string
            required:
              - key
              - item
              - product
              - status
              - by
              - skipReason
              - canStart
              - startsAfter
              - doItForMe
              - minutes
              - helpCenterUrl
              - names
            additionalProperties: false
        sections:
          type: array
          description: Every task, by product, in the order of the Setup page
          items:
            type: object
            properties:
              product:
                type: string
              done:
                type: integer
                minimum: -9007199254740991
                maximum: 9007199254740991
              total:
                description: Its tasks not skipped
                type: integer
                minimum: -9007199254740991
                maximum: 9007199254740991
              tasks:
                type: array
                items:
                  type: object
                  properties:
                    key:
                      description: >-
                        The Setup task, e.g. `connect_hris`, `connect_slack`,
                        `set_up_apple_mdm`, `turn_on_sentinelone`,
                        `open_first_country`
                      type: string
                    item:
                      description: >-
                        Which HRIS, platform or vendor, for a task repeated per
                        item (e.g. `payfit`, `apple_business`)
                      anyOf:
                        - type: string
                        - type: 'null'
                    product:
                      description: The section of the Setup page the task belongs to
                      type: string
                    status:
                      type: string
                      enum:
                        - TODO
                        - IN_PROGRESS
                        - DONE
                        - SKIPPED
                    by:
                      description: >-
                        Who moved it: ADMIN, PRIMO_AI, PRIMO, PRIMO_TEAM, or
                        DONE_WHEN when Primo found it done on its own; null when
                        nobody did
                      anyOf:
                        - type: string
                        - type: 'null'
                    skipReason:
                      description: >-
                        Why Primo AI skipped it, e.g. USES_SLACK,
                        NO_ANDROID_DEVICES
                      anyOf:
                        - type: string
                        - type: 'null'
                    canStart:
                      description: False while it waits for the tasks in `startsAfter`
                      type: boolean
                    startsAfter:
                      type: array
                      items:
                        type: string
                    doItForMe:
                      description: Primo AI can do this task for the company
                      type: boolean
                    minutes:
                      description: How long it takes by hand
                      anyOf:
                        - type: integer
                          minimum: -9007199254740991
                          maximum: 9007199254740991
                        - type: 'null'
                    helpCenterUrl:
                      anyOf:
                        - type: string
                        - type: 'null'
                    names:
                      description: >-
                        What Primo knows the task is about: the HRIS (`hris`),
                        the MDMs left (`mdms`), the admins, a country
                      type: object
                      propertyNames:
                        type: string
                      additionalProperties:
                        anyOf:
                          - type: string
                          - type: array
                            items:
                              type: string
                  required:
                    - key
                    - item
                    - product
                    - status
                    - by
                    - skipReason
                    - canStart
                    - startsAfter
                    - doItForMe
                    - minutes
                    - helpCenterUrl
                    - names
                  additionalProperties: false
            required:
              - product
              - done
              - total
              - tasks
            additionalProperties: false
        facts:
          type: object
          description: >-
            What Primo knows of the company's stack: devices, currentMdm, hris,
            emailProviders, chat, edr, buysDevices, admins
          propertyNames:
            type: string
          additionalProperties:
            type: object
            properties:
              value:
                anyOf:
                  - {}
                  - type: 'null'
              known:
                type: boolean
              source:
                description: DEAL, CALL, PLAIN_THREAD, PARTNER, ADMIN_ANSWER or PRIMO_TEAM
                anyOf:
                  - type: string
                  - type: 'null'
            required:
              - value
              - known
              - source
            additionalProperties: false
      required:
        - started
        - completedAt
        - upNext
        - sections
        - facts
      additionalProperties: false
  securitySchemes:
    apikey:
      scheme: bearer
      bearerFormat: API key
      type: http
      description: >-
        Use your Primo API key in the Authorization header as `Bearer
        <API_KEY>`.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.