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

# Login

> Exchange your identity (username, email, organisation name) and your organisation's API credential
(`client_id` and `client_secret`) for a bearer token valid for 60 minutes. The credential is issued per
organisation by Vortex IQ: contact [support](https://www.vortexiq.ai/contact-us) to have one provisioned.

The token acts as the person you name, within their organisation, with the credential's scopes
(`automations:read automations:write`). It never approves. Everything it creates is recorded as made by that
person through the API, with the credential's client id.

Send the request as JSON, as here, or as an OAuth 2.0 client-credentials form
(`application/x-www-form-urlencoded`, `grant_type=client_credentials`) with the client id and secret as HTTP
Basic authentication and `username`, `email` and `organization_name` as extra form fields, which is what
Postman's OAuth 2.0 helper sends. Values in the address are ignored: send everything in the body.

This endpoint is served by `https://app.vortexiq.ai`; every other endpoint by
`https://automations-api.vortexiq.ai`. Rate limited to 10 requests a minute.



## OpenAPI

````yaml automations/api/openapi.json POST /v2/api/automations/login
openapi: 3.1.0
info:
  title: Vortex IQ Automations API
  version: 1.0.0
  description: >
    REST API for Vortex IQ Automations. List the templates your organisation can
    use, set automations up on your

    stores, schedule them, run them, and follow every run, from your own tools
    instead of the Automations screens.


    The API is served from `https://automations-api.vortexiq.ai`; the login that
    gives you a token is on

    `https://app.vortexiq.ai`. Every call acts as the person who logged in,
    within their organisation, and every

    answer is JSON. See [Authentication](/automations/api/authentication).
  contact:
    name: Vortex IQ Support
    url: https://www.vortexiq.ai/contact-us
servers:
  - url: https://automations-api.vortexiq.ai
    description: Vortex IQ Automations (production)
security:
  - bearerAuth: []
  - apiCredential: []
tags:
  - name: Authentication
    description: >-
      Exchange your identity and your organisation's API credential for a bearer
      token.
  - name: Templates & stores
    description: What you can set up, and what it can run on.
  - name: Automations
    description: Set automations up, read them and change them.
  - name: Automation controls
    description: Pause, resume, archive and restore.
  - name: Runs
    description: Run an automation now, follow a run, read the history.
  - name: Schedules & calendar
    description: Preview a schedule, list the coming runs, move or skip one.
  - name: Approvals
    description: >-
      The runs waiting for a decision. Deciding happens in the Vortex IQ app
      only.
  - name: Imported workflows
    description: >-
      Bring an n8n or Shopify Flow workflow in, see how it would run, and run it
      as your own automation.
  - name: Status
    description: >-
      Whether Automations are on for your organisation, and how the service is
      doing.
paths:
  /v2/api/automations/login:
    post:
      tags:
        - Authentication
      summary: Login
      description: >-
        Exchange your identity (username, email, organisation name) and your
        organisation's API credential

        (`client_id` and `client_secret`) for a bearer token valid for 60
        minutes. The credential is issued per

        organisation by Vortex IQ: contact
        [support](https://www.vortexiq.ai/contact-us) to have one provisioned.


        The token acts as the person you name, within their organisation, with
        the credential's scopes

        (`automations:read automations:write`). It never approves. Everything it
        creates is recorded as made by that

        person through the API, with the credential's client id.


        Send the request as JSON, as here, or as an OAuth 2.0 client-credentials
        form

        (`application/x-www-form-urlencoded`, `grant_type=client_credentials`)
        with the client id and secret as HTTP

        Basic authentication and `username`, `email` and `organization_name` as
        extra form fields, which is what

        Postman's OAuth 2.0 helper sends. Values in the address are ignored:
        send everything in the body.


        This endpoint is served by `https://app.vortexiq.ai`; every other
        endpoint by

        `https://automations-api.vortexiq.ai`. Rate limited to 10 requests a
        minute.
      operationId: login
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - username
                - email
                - organization_name
                - client_id
                - client_secret
              properties:
                username:
                  type: string
                  description: >-
                    Your name as registered on your Vortex IQ account (first
                    name, last name, or full name; case-insensitive).
                  example: Jane Merchant
                email:
                  type: string
                  format: email
                  description: >-
                    The email of your Vortex IQ user. The account must be
                    active.
                  example: jane@example.com
                organization_name:
                  type: string
                  description: >-
                    Your organisation's name exactly as registered
                    (case-insensitive). Your user must belong to this
                    organisation.
                  example: Example Retail Ltd
                client_id:
                  type: string
                  description: >-
                    Your organisation's API client id, issued by Vortex IQ. It
                    starts with `viq_auto_`.
                  example: viq_auto_Ab12Cd34Ef56Gh78Ij90Kl12
                client_secret:
                  type: string
                  description: >-
                    Your organisation's API client secret. Shown once at issue
                    time; keep it server-side.
                  example: <client-secret>
                grant_type:
                  type: string
                  enum:
                    - client_credentials
                  description: >-
                    Optional. Sent by OAuth 2.0 clients; when present it must be
                    `client_credentials`.
            example:
              username: Jane Merchant
              email: jane@example.com
              organization_name: Example Retail Ltd
              client_id: viq_auto_Ab12Cd34Ef56Gh78Ij90Kl12
              client_secret: <client-secret>
      responses:
        '200':
          description: >-
            Authenticated. Send `access_token` as `Authorization: Bearer
            <token>` on every call to `https://automations-api.vortexiq.ai`.
          content:
            application/json:
              schema:
                type: object
                properties:
                  access_token:
                    type: string
                    description: The bearer token (a signed JWT). Treat it as a secret.
                  token_type:
                    type: string
                    example: Bearer
                  expires_in:
                    type: integer
                    description: Token lifetime in seconds (3600, one hour).
                    example: 3600
                  expires_at:
                    type: string
                    format: date-time
                    description: Absolute expiry time (ISO 8601).
                  scope:
                    type: string
                    description: >-
                      What the token may do, space-separated. A credential's
                      token never holds `automations:approve`.
                    example: automations:read automations:write
                  service_url:
                    type: string
                    description: Where to send the token.
                    example: https://automations-api.vortexiq.ai
                  direct:
                    type: boolean
                    description: >-
                      Used by the Vortex IQ app's own screens. You can ignore
                      it.
                  user:
                    type: object
                    properties:
                      email:
                        type: string
                      first_name:
                        type: string
                      last_name:
                        type: string
                  organization:
                    type: object
                    properties:
                      id:
                        type: integer
                      name:
                        type: string
              example:
                access_token: >-
                  eyJ0eXAiOiJhdCtqd3QiLCJhbGciOiJFZERTQSIsImtpZCI6InByb2R1Y3Rpb24tMSJ9...
                token_type: Bearer
                expires_in: 3600
                scope: automations:read automations:write
                service_url: https://automations-api.vortexiq.ai
                direct: true
                user:
                  email: jane@example.com
                  first_name: Jane
                  last_name: Merchant
                organization:
                  id: 42
                  name: Example Retail Ltd
                expires_at: '2026-10-16T10:26:00+00:00'
        '401':
          description: >-
            One of the provided values could not be validated. The answer is
            deliberately generic and takes the same time whichever value was
            wrong.
          content:
            application/json:
              example:
                error: invalid_credentials
                message: >-
                  The provided username, email, organization name or API
                  credential could not be validated.
        '422':
          description: >-
            A field is missing or malformed, or `grant_type` is not
            `client_credentials`.
          content:
            application/json:
              example:
                error: invalid_request
                message: Check the highlighted fields.
                errors:
                  client_secret:
                    - The client secret field is required.
        '429':
          description: >-
            More than 10 login attempts a minute from your address. Wait a
            minute and try again.
        '503':
          description: API access is not configured on this environment.
      security: []
      servers:
        - url: https://app.vortexiq.ai
          description: Vortex IQ platform (production)
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        A bearer token from [Login](/automations/api/login), sent as
        `Authorization: Bearer <token>`. Valid for 60 minutes; it acts as the
        person named at login, within their organisation, and never approves.
        Rotating or disabling the organisation's API credential ends every token
        made with it on its next call. See
        [Authentication](/automations/api/authentication).
    apiCredential:
      type: oauth2
      description: >-
        Your organisation's API credential, exchanged at
        [Login](/automations/api/login) for the bearer token above: an OAuth 2.0
        client-credentials request, with the `username`, `email` and
        `organization_name` of the person the token acts as sent as extra
        fields, as Postman's OAuth 2.0 helper can send them. The token never
        holds `automations:approve`.
      flows:
        clientCredentials:
          tokenUrl: https://app.vortexiq.ai/v2/api/automations/login
          scopes:
            automations:read: >-
              Read automations, templates, stores, runs, the calendar, approvals
              and imports.
            automations:write: >-
              Set automations up, change, pause, resume, archive, restore and
              run them; move and skip coming runs; keep and delete imports.

````

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