POST
/
v2
/
zaps
curl --request POST \
  --url https://api.zapier.com/v2/zaps \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "data": {
    "steps": [
      {
        "action": "example_core:5m2y9p7J",
        "inputs": {
          "code": "output = [{id: Math.round(Date.now()/1000), n: Math.random()}];"
        },
        "authentication": null
      },
      {
        "action": "example_core:VBz2NGB5",
        "inputs": {
          "code": "output = [{ id: inputData.id, n: inputData.n * 2}];",
          "inputs": {
            "n": "{{n}}",
            "id": "{{id}}"
          }
        },
        "authentication": null
      }
    ],
    "title": "My Critically Important Program"
  }
}'
{
  "type": "zap",
  "id": "104826128",
  "is_enabled": true,
  "last_successful_run_date": null,
  "updated_at": "2024-03-14T22:02:36+00:00",
  "title": "GENERATED ZAP CREATION E2E TEST - ZAP CONTAINS AUTHENTICATED AND UNAUTHENTICATED APP",
  "links": {
    "html_editor": "https://zapier.com/app/editor/104826128?utm_source=partner&utm_medium=embed&utm_campaign=partner_api&referer=None",
    "steps": [
      {
        "action": "core:Vn7xbE6k",
        "authentication": "Krjvl50K",
        "inputs": {},
        "title": null
      },
      {
        "action": "core:V7GpzX4m",
        "authentication": null,
        "inputs": null,
        "title": null
      }
    ]
  }
}

Authorizations

Authorization
string
headerrequired

Query Parameters

expand
string

A comma separated list of Zap fields that should be expanded from ids to full objects in the response. Fields that may not be expanded will remain as ids.

Body

data
object
required

See here to get started.

Response

201 - application/json
type
string
required

The type of this object.

id
string
required

A unique identifier of the Zap.

is_enabled
boolean
default: true

Whether the Zap is enabled (running) or not.

last_successful_run_date
string | null
required

The date/time at which this Zap last ran successfully. A null value indicates that a Zap has never run successfully.

updated_at
string
required
title
string
required

The human readable name of the Zap.

links
object
required
steps
required

ExpandedZapStep (Expandable)