zapier-platform-schema
Generated DocumentationThis is automatically generated by the npm run docs
command in zapier-platform-schema
version 8.2.1
.
Codifies high-level options for your app.
object
{ skipHttpPatch: true }
{ skipHttpPatch: false }
{}
{ blah: true }
{ skipHttpPatch: 'yes' }
Key | Required | Type | Description |
---|---|---|---|
skipHttpPatch |
no | boolean |
By default, Zapier patches the core http module so that all requests (including those from 3rd-party SDKs) can be logged. Set this to true if you’re seeing issues using an SDK (such as AWS). |
Represents a full app.
object
Key | Required | Type | Description |
---|---|---|---|
version |
yes | /VersionSchema | A version identifier for your code. |
platformVersion |
yes | /VersionSchema | A version identifier for the Zapier execution environment. |
beforeApp |
no | /MiddlewaresSchema | EXPERIMENTAL: Before the perform method is called on your app, you can modify the execution context. |
afterApp |
no | /MiddlewaresSchema | EXPERIMENTAL: After the perform method is called on your app, you can modify the response. |
authentication |
no | /AuthenticationSchema | Choose what scheme your API uses for authentication. |
requestTemplate |
no | /RequestSchema | Define a request mixin, great for setting custom headers, content-types, etc. |
beforeRequest |
no | /MiddlewaresSchema | Before an HTTP request is sent via our z.request() client, you can modify it. |
afterResponse |
no | /MiddlewaresSchema | After an HTTP response is recieved via our z.request() client, you can modify it. |
hydrators |
no | /HydratorsSchema | An optional bank of named functions that you can use in z.hydrate('someName') to lazily load data. |
resources |
no | /ResourcesSchema | All the resources for your app. Zapier will take these and generate the relevent triggers/searches/creates automatically. |
triggers |
no | /TriggersSchema | All the triggers for your app. You can add your own here, or Zapier will automatically register any from the list/hook methods on your resources. |
searches |
no | /SearchesSchema | All the searches for your app. You can add your own here, or Zapier will automatically register any from the search method on your resources. |
creates |
no | /CreatesSchema | All the creates for your app. You can add your own here, or Zapier will automatically register any from the create method on your resources. |
searchOrCreates |
no | /SearchOrCreatesSchema | All the search-or-create combos for your app. You can create your own here, or Zapier will automatically register any from resources that define a search, a create, and a get (or define a searchOrCreate directly). Register non-resource search-or-creates here as well. |
flags |
no | /AppFlagsSchema | Top-level app options |
Config for Basic Authentication. No extra properties are required to setup Basic Auth, so you can leave this empty if your app uses Basic Auth.
object
Config for custom authentication (like API keys). No extra properties are required to setup this auth type, so you can leave this empty if your app uses a custom auth method.
object
Config for Digest Authentication. No extra properties are required to setup Digest Auth, so you can leave this empty if your app uses Digets Auth.
object
Config for OAuth1 authentication.
object
Key | Required | Type | Description |
---|---|---|---|
getRequestToken |
yes | oneOf(/RequestSchema, /FunctionSchema) | Define where Zapier will acquire a request token which is used for the rest of the three legged authentication process. |
authorizeUrl |
yes | oneOf(/RedirectRequestSchema, /FunctionSchema) | Define where Zapier will redirect the user to authorize our app. Typically, you should append an oauth_token querystring parameter to the request. |
getAccessToken |
yes | oneOf(/RequestSchema, /FunctionSchema) | Define how Zapier fetches an access token from the API |
Config for OAuth2 authentication.
object
Key | Required | Type | Description |
---|---|---|---|
authorizeUrl |
yes | oneOf(/RedirectRequestSchema, /FunctionSchema) | Define where Zapier will redirect the user to authorize our app. Note: we append the redirect URL and state parameters to return value of this function. |
getAccessToken |
yes | oneOf(/RequestSchema, /FunctionSchema) | Define how Zapier fetches an access token from the API |
refreshAccessToken |
no | oneOf(/RequestSchema, /FunctionSchema) | Define how Zapier will refresh the access token from the API |
scope |
no | string |
What scope should Zapier request? |
autoRefresh |
no | boolean |
Should Zapier include a pre-built afterResponse middleware that invokes refreshAccessToken when we receive a 401 response? |
Represents authentication schemes.
object
{ type: 'basic', test: '$func$2$f$' }
{ type: 'custom', test: '$func$2$f$', fields: [ { key: 'abc' } ] }
{ type: 'custom', test: '$func$2$f$', connectionLabel: '{{bundle.inputData.abc}}' }
{ type: 'custom', test: '$func$2$f$', connectionLabel: '$func$2$f$' }
{ type: 'custom', test: '$func$2$f$', connectionLabel: { url: 'abc' } }
{}
'$func$2$f$'
{ type: 'unknown', test: '$func$2$f$' }
{ type: 'custom', test: '$func$2$f$', fields: '$func$2$f$' }
{ type: 'custom', test: '$func$2$f$', fields: [ { key: 'abc' }, '$func$2$f$' ] }
Key | Required | Type | Description |
---|---|---|---|
type |
yes | string in ('basic' , 'custom' , 'digest' , 'oauth1' , 'oauth2' , 'session' ) |
Choose which scheme you want to use. |
test |
yes | oneOf(/RequestSchema, /FunctionSchema) | A function or request that confirms the authentication is working. |
fields |
no | /FieldsSchema | Fields you can request from the user before they connect your app to Zapier. |
connectionLabel |
no | anyOf(/RequestSchema, /FunctionSchema, string ) |
A string with variables, function, or request that returns the connection label for the authenticated user. |
basicConfig |
no | /AuthenticationBasicConfigSchema | No description given. |
customConfig |
no | /AuthenticationCustomConfigSchema | No description given. |
digestConfig |
no | /AuthenticationDigestConfigSchema | No description given. |
oauth1Config |
no | /AuthenticationOAuth1ConfigSchema | No description given. |
oauth2Config |
no | /AuthenticationOAuth2ConfigSchema | No description given. |
sessionConfig |
no | /AuthenticationSessionConfigSchema | No description given. |
Config for session authentication.
object
Key | Required | Type | Description |
---|---|---|---|
perform |
yes | oneOf(/RequestSchema, /FunctionSchema) | Define how Zapier fetches the additional authData needed to make API calls. |
Represents the fundamental mechanics of a search/create.
object
Key | Required | Type | Description |
---|---|---|---|
resource |
no | /RefResourceSchema | Optionally reference and extends a resource. Allows Zapier to automatically tie together samples, lists and hooks, greatly improving the UX. EG: if you had another trigger reusing a resource but filtering the results. |
perform |
yes | oneOf(/RequestSchema, /FunctionSchema) | How will Zapier get the data? This can be a function like (z) => [{id: 123}] or a request like {url: 'http...'} . |
performResume |
no | /FunctionSchema | A function that parses data from a perform + callback to resume this action. For use with callback semantics |
performGet |
no | oneOf(/RequestSchema, /FunctionSchema) | How will Zapier get a single record? If you find yourself reaching for this - consider resources and their built-in get methods. |
inputFields |
no | /DynamicFieldsSchema | What should the form a user sees and configures look like? |
outputFields |
no | /DynamicFieldsSchema | What fields of data will this return? Will use resource outputFields if missing, will also use sample if available. |
sample |
yes (with exceptions, see description) | object |
What does a sample of data look like? Will use resource sample if missing. Requirement waived if display.hidden is true or if this belongs to a resource that has a top-level sample |
Represents the fundamental mechanics of a create.
object
Key | Required | Type | Description |
---|---|---|---|
resource |
no | /RefResourceSchema | Optionally reference and extends a resource. Allows Zapier to automatically tie together samples, lists and hooks, greatly improving the UX. EG: if you had another trigger reusing a resource but filtering the results. |
perform |
yes | oneOf(/RequestSchema, /FunctionSchema) | How will Zapier get the data? This can be a function like (z) => [{id: 123}] or a request like {url: 'http...'} . |
performResume |
no | /FunctionSchema | A function that parses data from a perform + callback to resume this action. For use with callback semantics |
performGet |
no | oneOf(/RequestSchema, /FunctionSchema) | How will Zapier get a single record? If you find yourself reaching for this - consider resources and their built-in get methods. |
inputFields |
no | /DynamicFieldsSchema | What should the form a user sees and configures look like? |
outputFields |
no | /DynamicFieldsSchema | What fields of data will this return? Will use resource outputFields if missing, will also use sample if available. |
sample |
yes (with exceptions, see description) | object |
What does a sample of data look like? Will use resource sample if missing. Requirement waived if display.hidden is true or if this belongs to a resource that has a top-level sample |
shouldLock |
no | boolean |
Should this action be performed one at a time (avoid concurrency)? |
Represents user information for a trigger, search, or create.
object
{ label: 'New Thing', description: 'Gets a new thing for you.' }
{ label: 'New Thing',
description: 'Gets a new thing for you.',
directions: 'This is how you use the thing.',
hidden: false,
important: true }
{ label: 'New Thing' }
{ label: 'New Thing', description: 'Gets a new thing for you.', important: 1 }
Key | Required | Type | Description |
---|---|---|---|
label |
yes | string |
A short label like “New Record” or “Create Record in Project”. |
description |
yes | string |
A description of what this trigger, search, or create does. |
directions |
no | string |
A short blurb that can explain how to get this working. EG: how and where to copy-paste a static hook URL into your application. Only evaluated for static webhooks. |
important |
no | boolean |
Affects how prominently this operation is displayed in the UI. Only mark a few of the most popular operations important. |
hidden |
no | boolean |
Should this operation be unselectable by users? |
Represents the inbound mechanics of hooks with optional subscribe/unsubscribe. Defers to list for fields.
object
Key | Required | Type | Description |
---|---|---|---|
type |
yes (with exceptions, see description) | string in ('hook' ) |
Must be explicitly set to "hook" unless this hook is defined as part of a resource, in which case it’s optional. |
resource |
no | /RefResourceSchema | Optionally reference and extends a resource. Allows Zapier to automatically tie together samples, lists and hooks, greatly improving the UX. EG: if you had another trigger reusing a resource but filtering the results. |
perform |
yes | /FunctionSchema | A function that processes the inbound webhook request. |
performList |
yes (with exceptions, see description) | oneOf(/RequestSchema, /FunctionSchema) | Can get “live” data on demand instead of waiting for a hook. If you find yourself reaching for this - consider resources and their built-in hook/list methods. Note: this is required for public apps to ensure the best UX for the end-user. For private apps, you can ignore warnings about this property with the --without-style flag during zapier push . |
performSubscribe |
yes (with exceptions, see description) | oneOf(/RequestSchema, /FunctionSchema) | Takes a URL and any necessary data from the user and subscribes. Note: this is required for public apps to ensure the best UX for the end-user. For private apps, you can ignore warnings about this property with the --without-style flag during zapier push . |
performUnsubscribe |
yes (with exceptions, see description) | oneOf(/RequestSchema, /FunctionSchema) | Takes a URL and data from a previous subscribe call and unsubscribes. Note: this is required for public apps to ensure the best UX for the end-user. For private apps, you can ignore warnings about this property with the --without-style flag during zapier push . |
inputFields |
no | /DynamicFieldsSchema | What should the form a user sees and configures look like? |
outputFields |
no | /DynamicFieldsSchema | What fields of data will this return? Will use resource outputFields if missing, will also use sample if available. |
sample |
yes (with exceptions, see description) | object |
What does a sample of data look like? Will use resource sample if missing. Requirement waived if display.hidden is true or if this belongs to a resource that has a top-level sample |
Represents the fundamental mechanics of triggers, searches, or creates.
object
Key | Required | Type | Description |
---|---|---|---|
resource |
no | /RefResourceSchema | Optionally reference and extends a resource. Allows Zapier to automatically tie together samples, lists and hooks, greatly improving the UX. EG: if you had another trigger reusing a resource but filtering the results. |
perform |
yes | oneOf(/RequestSchema, /FunctionSchema) | How will Zapier get the data? This can be a function like (z) => [{id: 123}] or a request like {url: 'http...'} . |
inputFields |
no | /DynamicFieldsSchema | What should the form a user sees and configures look like? |
outputFields |
no | /DynamicFieldsSchema | What fields of data will this return? Will use resource outputFields if missing, will also use sample if available. |
sample |
yes (with exceptions, see description) | object |
What does a sample of data look like? Will use resource sample if missing. Requirement waived if display.hidden is true or if this belongs to a resource that has a top-level sample |
Represents the fundamental mechanics of a trigger.
object
Key | Required | Type | Description |
---|---|---|---|
type |
no | string in ('polling' ) |
Clarify how this operation works (polling == pull or hook == push). |
resource |
no | /RefResourceSchema | Optionally reference and extends a resource. Allows Zapier to automatically tie together samples, lists and hooks, greatly improving the UX. EG: if you had another trigger reusing a resource but filtering the results. |
perform |
yes | oneOf(/RequestSchema, /FunctionSchema) | How will Zapier get the data? This can be a function like (z) => [{id: 123}] or a request like {url: 'http...'} . |
canPaginate |
no | boolean |
Does this endpoint support a page offset? |
inputFields |
no | /DynamicFieldsSchema | What should the form a user sees and configures look like? |
outputFields |
no | /DynamicFieldsSchema | What fields of data will this return? Will use resource outputFields if missing, will also use sample if available. |
sample |
yes (with exceptions, see description) | object |
What does a sample of data look like? Will use resource sample if missing. Requirement waived if display.hidden is true or if this belongs to a resource that has a top-level sample |
How will Zapier create a new object?
object
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Create Recipe', description: 'Creates a new recipe.' },
operation: { perform: '$func$2$f$', sample: { id: 1 } } }
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Create Recipe', description: 'Creates a new recipe.' },
operation: { perform: '$func$2$f$', sample: { id: 1 }, shouldLock: true } }
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Create Recipe', description: 'Creates a new recipe.', hidden: true },
operation: { perform: '$func$2$f$' } }
'abc'
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Create Recipe', description: 'Creates a new recipe.' },
operation: { perform: '$func$2$f$', shouldLock: 'yes' } }
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Create Recipe', description: 'Creates a new recipe.' },
operation: { perform: '$func$2$f$' } }
Key | Required | Type | Description |
---|---|---|---|
key |
yes | /KeySchema | A key to uniquely identify this create. |
noun |
yes | string |
A noun for this create that completes the sentence “creates a new XXX”. |
display |
yes | /BasicDisplaySchema | Configures the UI for this create. |
operation |
yes | /BasicCreateActionOperationSchema | Powers the functionality for this create. |
Enumerates the creates your app has available for users.
object
Key | Required | Type | Description |
---|---|---|---|
^[a-zA-Z]+[a-zA-Z0-9_]*$ |
no | /CreateSchema | Any unique key can be used and its values will be validated against the CreateSchema. |
Like /FieldsSchema but you can provide functions to create dynamic or custom fields.
[]
[ { key: 'abc' } ]
[ { key: 'abc' }, '$func$2$f$' ]
[ '$func$2$f$', '$func$2$f$' ]
[ {} ]
[ { key: 'abc', choices: {} } ]
'$func$2$f$'
An object describing a labeled choice in a static dropdown. Useful if the value a user picks isn’t exactly what the zap uses. For instance, when they click on a nickname, but the zap uses the user’s full name (image).
object
{ label: 'Red', sample: '#f00', value: '#f00' }
{ label: 'Red', value: '#f00' }
Key | Required | Type | Description |
---|---|---|---|
value |
yes | string |
The actual value that is sent into the Zap. Should match sample exactly. |
sample |
yes | string |
Displayed as light grey text in the editor. It’s important that the value match the sample. Otherwise, the actual value won’t match what the user picked, which is confusing. |
label |
yes | string |
A human readable label for this value. |
A static dropdown of options. Which you use depends on your order and label requirements:
Need a Label? | Does Order Matter? | Type to Use |
---|---|---|
Yes | No | Object of value -> label |
No | Yes | Array of Strings |
Yes | Yes | Array of FieldChoiceWithLabel |
object
, array
[oneOf(string
, /FieldChoiceWithLabelSchema)]){ a: '1', b: '2', c: '3' }
[ 'first', 'second', 'third' ]
[ 1, 2, 3 ]
[ { a: '1', b: '2', c: '3' } ]
Represents an array of fields or functions.
array
[oneOf(/FieldSchema, /FunctionSchema)][]
[ { key: 'abc' } ]
[ { key: 'abc' }, '$func$2$f$' ]
[ '$func$2$f$', '$func$2$f$' ]
[ {} ]
[ { key: 'abc', choices: {} } ]
'$func$2$f$'
Defines a field an app either needs as input, or gives as output. In addition to the requirements below, the following keys are mutually exclusive:
children
& list
children
& dict
children
& type
children
& placeholder
children
& helpText
children
& default
dict
& list
dynamic
& dict
dynamic
& choices
object
{ key: 'abc' }
{ key: 'abc', choices: { mobile: 'Mobile Phone' } }
{ key: 'abc', choices: [ 'first', 'second', 'third' ] }
{ key: 'abc', choices: [ { label: 'Red', sample: '#f00', value: '#f00' } ] }
{ key: 'abc', children: [ { key: 'abc' } ] }
{ key: 'abc', type: 'integer', helpText: 'neat' }
{}
{ key: 'abc', choices: {} }
{ key: 'abc', choices: [] }
{ key: 'abc', choices: [ 3 ] }
{ key: 'abc', choices: [ { label: 'Red', value: '#f00' } ] }
{ key: 'abc', choices: 'mobile' }
{ key: 'abc', type: 'loltype' }
{ key: 'abc', children: [], helpText: '' }
{ key: 'abc', children: [ { key: 'def', children: [] } ] }
{ key: 'abc', children: [ { key: 'def', children: [ { key: 'dhi' } ] } ] }
{ key: 'abc', children: [ '$func$2$f$' ] }
Key | Required | Type | Description |
---|---|---|---|
key |
yes | string |
A unique machine readable key for this value (IE: “fname”). |
label |
no | string |
A human readable label for this value (IE: “First Name”). |
helpText |
no | string |
A human readable description of this value (IE: “The first part of a full name.”). You can use Markdown. |
type |
no | string in ('string' , 'text' , 'integer' , 'number' , 'boolean' , 'datetime' , 'file' , 'password' , 'copy' ) |
The type of this value. |
required |
no | boolean |
If this value is required or not. |
placeholder |
no | string |
An example value that is not saved. |
default |
no | string |
A default value that is saved the first time a Zap is created. |
dynamic |
no | /RefResourceSchema | A reference to a trigger that will power a dynamic dropdown. |
search |
no | /RefResourceSchema | A reference to a search that will guide the user to add a search step to populate this field when creating a Zap. |
choices |
no | /FieldChoicesSchema | An object of machine keys and human values to populate a static dropdown. |
list |
no | boolean |
Can a user provide multiples of this field? |
children |
no | array [/FieldSchema] |
An array of child fields that define the structure of a sub-object for this field. Usually used for line items. |
dict |
no | boolean |
Is this field a key/value input? |
computed |
no | boolean |
Is this field automatically populated (and hidden from the user)? |
altersDynamicFields |
no | boolean |
Does the value of this field affect the definitions of other fields in the set? |
inputFormat |
no | string |
Useful when you expect the input to be part of a longer string. Put “{{input}}” in place of the user’s input (IE: “https://{{input}}.yourdomain.com”). |
An array or collection of fields.
array
[/FieldSchema]An object whose values can only be primitives
object
{ a: 1, b: 2, c: 3 }
{ a: 1.2, b: 2.2, c: 3.3 }
{ a: 'a', b: 'b', c: 'c' }
{ a: true, b: true, c: false }
{ a: 'a', b: 2, c: 3.1, d: true, e: false }
{ '123': 'hello' }
{ a: {}, b: 2 }
{ a: { aa: 1 }, b: 2 }
{ a: [], b: 2 }
{ a: [ 1, 2, 3 ], b: 2 }
{ '': 1 }
{ ' ': 1 }
{ ' ': 1 }
Key | Required | Type | Description |
---|---|---|---|
[^\s]+ |
no | anyOf(null , string , integer , number , boolean ) |
Any key may exist in this flat object as long as its values are simple. |
A path to a file that might have content like module.exports = (z, bundle) => [{id: 123}];
.
object
{ require: 'some/path/to/file.js' }
Key | Required | Type | Description |
---|---|---|---|
require |
yes | string |
No description given. |
Internal pointer to a function from the original source or the source code itself. Encodes arity and if arguments
is used in the body. Note - just write normal functions and the system will encode the pointers for you. Or, provide {source: “return 1 + 2”} and the system will wrap in a function for you.
string
, /FunctionRequireSchema, /FunctionSourceSchema)'$func$0$f$'
'$func$2$t$'
{ source: 'return 1 + 2' }
{ require: 'some/path/to/file.js' }
'funcy'
{ source: '1 + 2' }
{ source: '1 + 2', require: 'some/path/to/file.js' }
Source code like {source: "return 1 + 2"}
which the system will wrap in a function for you.
object
{ source: 'return 1 + 2' }
{ args: [ 'x', 'y' ], source: 'return x + y;' }
{ source: '1 + 2' }
Key | Required | Type | Description |
---|---|---|---|
source |
yes | string |
JavaScript code for the function body. This must end with a return statement. |
args |
no | array [string ] |
Function signature. Defaults to ['z', 'bundle'] if not specified. |
A bank of named functions that you can use in z.hydrate('someName')
to lazily load data.
object
Key | Required | Type | Description |
---|---|---|---|
^[a-zA-Z]+[a-zA-Z0-9]*$ |
no | /FunctionSchema | Any unique key can be used in z.hydrate('uniqueKeyHere') . |
A unique identifier for this item.
string
^[a-zA-Z]+[a-zA-Z0-9_]*$
List of before or after middlewares. Can be an array of functions or a single function
array
[/FunctionSchema], /FunctionSchema)A representation of a HTTP redirect - you can use the {{syntax}}
to inject authentication, field or global variables.
object
Key | Required | Type | Description |
---|---|---|---|
method |
no | string in ('GET' ) |
The HTTP method for the request. |
url |
no | string |
A URL for the request (we will parse the querystring and merge with params). Keys and values will not be re-encoded. |
params |
no | /FlatObjectSchema | A mapping of the querystring - will get merged with any query params in the URL. Keys and values will be encoded. |
Reference a resource by key and the data it returns. In the format of: {resource_key}.{foreign_key}(.{human_label_key})
.
string
^[a-zA-Z0-9_]+(\.[a-zA-Z0-9_]+)?(\.[a-zA-Z0-9_]+)?$
'contact'
'contact.id'
'contact.id.full_name'
'Contact.list.id.full_name'
A representation of a HTTP request - you can use the {{syntax}}
to inject authentication, field or global variables.
object
Key | Required | Type | Description |
---|---|---|---|
method |
no | string in ('GET' , 'PUT' , 'POST' , 'PATCH' , 'DELETE' , 'HEAD' ) |
The HTTP method for the request. |
url |
no | string |
A URL for the request (we will parse the querystring and merge with params). Keys and values will not be re-encoded. |
body |
no | oneOf(null , string , object , array ) |
Can be nothing, a raw string or JSON (object or array). |
params |
no | /FlatObjectSchema | A mapping of the querystring - will get merged with any query params in the URL. Keys and values will be encoded. |
headers |
no | /FlatObjectSchema | The HTTP headers for the request. |
auth |
no | oneOf(array [string ], /FlatObjectSchema) |
An object holding the auth parameters for OAuth1 request signing, like {oauth_token: 'abcd', oauth_token_secret: '1234'} . Or an array reserved (i.e. not implemented yet) to hold the username and password for Basic Auth. Like ['AzureDiamond', 'hunter2'] . |
removeMissingValuesFrom |
no | object |
Should missing values be sent? (empty strings, null , and undefined only — [] , {} , and false will still be sent). Allowed fields are params and body . The default is false , ex: removeMissingValuesFrom: { params: false, body: false } |
How will we find create a specific object given inputs? Will be turned into a create automatically.
object
{ display: { label: 'Create Tag', description: 'Create a new Tag in your account.' },
operation: { perform: '$func$2$f$', sample: { id: 1 } } }
{ display: { label: 'Create Tag', description: 'Create a new Tag in your account.', hidden: true },
operation: { perform: '$func$2$f$' } }
{ display: { label: 'Create Tag', description: 'Create a new Tag in your account.' },
operation: { perform: '$func$2$f$' } }
Key | Required | Type | Description |
---|---|---|---|
display |
yes | /BasicDisplaySchema | Define how this create method will be exposed in the UI. |
operation |
yes | /BasicActionOperationSchema | Define how this create method will work. |
How will we get a single object given a unique identifier/id?
object
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.' },
operation: { perform: { url: '$func$0$f$' }, sample: { id: 385, name: 'proactive enable ROI' } } }
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.', hidden: true },
operation: { perform: { url: '$func$0$f$' } } }
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.' },
operation: { perform: { url: '$func$0$f$' } } }
Key | Required | Type | Description |
---|---|---|---|
display |
yes | /BasicDisplaySchema | Define how this get method will be exposed in the UI. |
operation |
yes | /BasicOperationSchema | Define how this get method will work. |
How will we get notified of new objects? Will be turned into a trigger automatically.
object
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.' },
operation: { type: 'hook', perform: '$func$0$f$', sample: { id: 385, name: 'proactive enable ROI' } } }
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.', hidden: true },
operation: { type: 'hook', perform: '$func$0$f$' } }
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.' },
operation: { type: 'hook', perform: '$func$0$f$' } }
Key | Required | Type | Description |
---|---|---|---|
display |
yes | /BasicDisplaySchema | Define how this hook/trigger method will be exposed in the UI. |
operation |
yes | /BasicHookOperationSchema | Define how this hook/trigger method will work. |
How will we get a list of new objects? Will be turned into a trigger automatically.
object
{ display: { label: 'New User', description: 'Trigger when a new User is created in your account.' },
operation:
{ perform: { url: 'http://fake-crm.getsandbox.com/users' },
sample: { id: 49, name: 'Veronica Kuhn', email: 'veronica.kuhn@company.com' } } }
{ display:
{ label: 'New User',
description: 'Trigger when a new User is created in your account.',
hidden: true },
operation: { perform: { url: 'http://fake-crm.getsandbox.com/users' } } }
{ display: { label: 'New User', description: 'Trigger when a new User is created in your account.' },
operation: { perform: { url: 'http://fake-crm.getsandbox.com/users' } } }
Key | Required | Type | Description |
---|---|---|---|
display |
yes | /BasicDisplaySchema | Define how this list/trigger method will be exposed in the UI. |
operation |
yes | /BasicPollingOperationSchema | Define how this list/trigger method will work. |
How will we find a specific object given filters or search terms? Will be turned into a search automatically.
object
{ display: { label: 'Find a Recipe', description: 'Search for recipe by cuisine style.' },
operation: { perform: '$func$2$f$', sample: { id: 1 } } }
{ display: { label: 'Find a Recipe', description: 'Search for recipe by cuisine style.', hidden: true },
operation: { perform: '$func$2$f$' } }
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Find a Recipe', description: 'Search for recipe by cuisine style.' },
operation: { perform: '$func$2$f$' } }
Key | Required | Type | Description |
---|---|---|---|
display |
yes | /BasicDisplaySchema | Define how this search method will be exposed in the UI. |
operation |
yes | /BasicActionOperationSchema | Define how this search method will work. |
Represents a resource, which will in turn power triggers, searches, or creates.
object
{ key: 'tag',
noun: 'Tag',
get:
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.' },
operation:
{ perform: { url: 'http://fake-crm.getsandbox.com/tags/{{inputData.id}}' },
sample: { id: 385, name: 'proactive enable ROI' } } } }
{ key: 'tag',
noun: 'Tag',
sample: { id: 385, name: 'proactive enable ROI' },
get:
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.' },
operation: { perform: { url: 'http://fake-crm.getsandbox.com/tags/{{inputData.id}}' } } } }
{ key: 'tag',
noun: 'Tag',
get:
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.', hidden: true },
operation: { perform: { url: 'http://fake-crm.getsandbox.com/tags/{{inputData.id}}' } } },
list:
{ display: { label: 'New Tag', description: 'Trigger when a new Tag is created in your account.' },
operation:
{ perform: { url: 'http://fake-crm.getsandbox.com/tags' },
sample: { id: 385, name: 'proactive enable ROI' } } } }
{ key: 'tag',
noun: 'Tag',
get:
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.' },
operation: { perform: { url: 'http://fake-crm.getsandbox.com/tags/{{inputData.id}}' } } },
list:
{ display: { label: 'New Tag', description: 'Trigger when a new Tag is created in your account.' },
operation:
{ perform: { url: 'http://fake-crm.getsandbox.com/tags' },
sample: { id: 385, name: 'proactive enable ROI' } } } }
{ key: 'tag',
noun: 'Tag',
get:
{ display: { label: 'Get Tag by ID', description: 'Grab a specific Tag by ID.' },
operation: { perform: { url: 'http://fake-crm.getsandbox.com/tags/{{inputData.id}}' } } } }
Key | Required | Type | Description |
---|---|---|---|
key |
yes | /KeySchema | A key to uniquely identify this resource. |
noun |
yes | string |
A noun for this resource that completes the sentence “create a new XXX”. |
get |
no | /ResourceMethodGetSchema | How will we get a single object given a unique identifier/id? |
hook |
no | /ResourceMethodHookSchema | How will we get notified of new objects? Will be turned into a trigger automatically. |
list |
no | /ResourceMethodListSchema | How will we get a list of new objects? Will be turned into a trigger automatically. |
search |
no | /ResourceMethodSearchSchema | How will we find a specific object given filters or search terms? Will be turned into a search automatically. |
create |
no | /ResourceMethodCreateSchema | How will we find create a specific object given inputs? Will be turned into a create automatically. |
outputFields |
no | /DynamicFieldsSchema | What fields of data will this return? |
sample |
no | object |
What does a sample of data look like? |
All the resources that underlie common CRUD methods powering automatically handled triggers, creates, and searches for your app. Zapier will break these apart for you.
object
Key | Required | Type | Description |
---|---|---|---|
^[a-zA-Z]+[a-zA-Z0-9_]*$ |
no | /ResourceSchema | Any unique key can be used and its values will be validated against the ResourceSchema. |
An array of objects suitable for returning in perform calls.
array
[object
]Pair an existing search and a create to enable “Find or Create” functionality in your app
object
Key | Required | Type | Description |
---|---|---|---|
key |
yes | /KeySchema | A key to uniquely identify this search-or-create. Must match the search key. |
display |
yes | /BasicDisplaySchema | Configures the UI for this search-or-create. |
search |
yes | /KeySchema | The key of the search that powers this search-or-create |
create |
yes | /KeySchema | The key of the create that powers this search-or-create |
Enumerates the search-or-creates your app has available for users.
object
Key | Required | Type | Description |
---|---|---|---|
^[a-zA-Z]+[a-zA-Z0-9_]*$ |
no | /SearchOrCreateSchema | Any unique key can be used and its values will be validated against the SearchOrCreateSchema. |
How will Zapier search for existing objects?
object
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Find a Recipe', description: 'Search for recipe by cuisine style.' },
operation: { perform: '$func$2$f$', sample: { id: 1 } } }
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Find a Recipe', description: 'Search for recipe by cuisine style.', hidden: true },
operation: { perform: '$func$2$f$' } }
'abc'
{ key: 'recipe',
noun: 'Recipe',
display: { label: 'Find a Recipe', description: 'Search for recipe by cuisine style.' },
operation: { perform: '$func$2$f$' } }
Key | Required | Type | Description |
---|---|---|---|
key |
yes | /KeySchema | A key to uniquely identify this search. |
noun |
yes | string |
A noun for this search that completes the sentence “finds a specific XXX”. |
display |
yes | /BasicDisplaySchema | Configures the UI for this search. |
operation |
yes | /BasicActionOperationSchema | Powers the functionality for this search. |
Enumerates the searches your app has available for users.
object
Key | Required | Type | Description |
---|---|---|---|
^[a-zA-Z]+[a-zA-Z0-9_]*$ |
no | /SearchSchema | Any unique key can be used and its values will be validated against the SearchSchema. |
How will Zapier get notified of new objects?
object
{ key: 'new_recipe',
noun: 'Recipe',
display: { label: 'New Recipe', description: 'Triggers when a new recipe is added.' },
operation: { type: 'polling', perform: '$func$0$f$', sample: { id: 1 } } }
{ key: 'new_recipe',
noun: 'Recipe',
display: { label: 'New Recipe', description: 'Triggers when a new recipe is added.', hidden: true },
operation: { type: 'polling', perform: '$func$0$f$' } }
{ key: 'new_recipe',
noun: 'Recipe',
display: { label: 'New Recipe', description: 'Triggers when a new recipe is added.' },
operation: { perform: '$func$0$f$' } }
Key | Required | Type | Description |
---|---|---|---|
key |
yes | /KeySchema | A key to uniquely identify this trigger. |
noun |
yes | string |
A noun for this trigger that completes the sentence “triggers on a new XXX”. |
display |
yes | /BasicDisplaySchema | Configures the UI for this trigger. |
operation |
yes | anyOf(/BasicPollingOperationSchema, /BasicHookOperationSchema) | Powers the functionality for this trigger. |
Enumerates the triggers your app has available for users.
object
Key | Required | Type | Description |
---|---|---|---|
^[a-zA-Z]+[a-zA-Z0-9_]*$ |
no | /TriggerSchema | Any unique key can be used and its values will be validated against the TriggerSchema. |
Represents a simplified semver string, from 0.0.0
to 999.999.999
.
string
^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$
'1.0.0'
'2.11.3'
'999.999.999'
'1.0.0.0'
'1000.0.0'
'v1.0.0'
'1.0.0-beta'
'1.0.0-beta.x.y.z'
'1.0.0-beta+12487'