LogoLogo
Back to studio
  • Formsort documentation
  • โฉQuickstart
    • ๐ŸŸขGet started with Formsort
    • ๐ŸŽCore concepts
    • โ„น๏ธQuestion and content reference
    • ๐Ÿ“•Key terms
    • ๐Ÿž๏ธCreate your first flow
    • ๐Ÿ“–Add content and collect answers
      • ๐ŸคณCapture demographic data
      • โ„น๏ธAdd informational content
      • ๐Ÿ” Review your variable schema
    • ๐ŸŽจCreate a theme
      • Set brand guidelines
    • ๐ŸคนPersonalize your flow
      • ๐ŸŒŸTemplate your variables
      • ๐Ÿง Add conditional logic
      • ๐Ÿ’ซUsing conditional logic with Calculated and API variables
      • ๐Ÿ”šEnd the flow
    • ๐Ÿ”€Set up integrations
    • ๐Ÿš€Go live
      • Auditing your flow for content, functionality, and design
    • ๐Ÿ’ผCommon use cases
      • ๐Ÿ’”Disqualify responders
      • ๐Ÿ—“๏ธAdd a scheduling option
      • ๐Ÿ“„Allow responders to read and accept your company policies
  • ๐Ÿ—๏ธBuilding flows
    • Flows and variants
      • Flow starts
    • Adding content
      • Groups
      • Steps
        • Settings
        • Logic
        • Style
      • Questions
        • General Settings
        • Style
        • Address
        • Comparison
        • Confirmation
        • Date
        • Date & Time
        • Email address
        • File upload
        • Grid choice
        • Iframe
        • Image upload
        • Number
        • Payment
        • Phone number
        • Postal code
        • Question group
        • Region
        • Select
          • Providing choices via API or calculation
        • Signature
        • SSN
        • Text questions
        • Yes/No
      • Content
        • General Settings
        • Statement
        • Image
        • Video
        • Next button
        • Divider
        • Map
      • Endings
      • Using markdown
      • Using variable templating
        • Template formatting functions
      • Copy-pasting form content
      • Content library
    • Conditions and logic
      • Logical operator reference
      • Advanced logic
    • Variables (answers)
      • Variables from questions
      • Externally provided variables
      • Calculated variables
      • API lookups
      • System Library variables
      • Orphaned variables
    • Schemas
      • JSON Schemas
      • Validating flow schemas
    • Redirects
    • Styling and themes
      • CSS Reference
      • Overriding theme styling
      • Custom CSS overrides
      • Content area
      • Animations and transitions
      • Form Layout
      • Typography
        • Adobe Fonts
        • Hosting custom fonts
      • Color variables
      • Dimension variables
      • Question containers
      • Assets
      • Form Buttons
        • Select buttons
      • Inputs and dropdowns
      • Checkmarks
      • Tables
      • Sliders
      • Divider lines
      • Progress bar
      • Comparison cards
    • Variant settings
      • Form behavior for returning responders
      • Group ranking API
    • Publishing and versions
      • Preview window
      • Deploying
      • History
  • ๐Ÿ’พHandling data
    • Philosophy and data retention policy
    • Viewing form answers
    • Responder UUIDs
    • Environments
      • Loading different environments
    • Passing data in
      • URL parameters
      • POST body
      • Embed query parameters
    • Custom validators
    • Form answers and events
      • Analytics events
      • Signed requests
      • Event payload shape
      • Submission frequencies
      • Runtime error reporting
      • Admin API
      • Flow content data format
    • Integration reference
      • Amplitude
        • Amplitude cross domain tracking
      • BigQuery
      • FullStory
      • Google Analytics
        • Updating from Universal Analytics to GA4
      • Google Cloud Storage
      • Google Sheets
      • Google Tag Manager (GTM)
        • JavaScript triggered by flow events
      • Hubspot
      • Jornaya
      • Optimizely
      • PostgreSQL
      • Redshift
      • Rudderstack
      • S3
      • Salesforce
      • Segment
        • Segment Setup
        • Segment cross domain tracking
      • Stripe
      • TrustedForm
      • Webhooks
        • Zapier
  • ๐Ÿ“บGoing live
    • Custom domains
    • Built-in analytics
    • Embedding
      • Web-Embed API
        • React-embed
      • Adding authentication
      • Embedding forms in iOS and Android
      • Setting up a dev environment
    • Split testing
    • Preflight checklist
  • ๐ŸขTeams
    • Accounts
      • Roles and permissions
    • Events subscriptions
    • Workspace domain detection
Powered by GitBook
On this page
  • Setup
  • Authentication
  • Pagination
  • JSON
  • Readonly resources
  • Obtain specification
  • List flows
  • List variants for a flow
  • List environments for a flow
  • List deployments of a particular variant
  • List available themes
  • Get details of a specific variant revision
  • Action resources
  • Create a new deployment of a variant revision

Was this helpful?

  1. Handling data
  2. Form answers and events

Admin API

Programmatic access to flows, variants, and deployments using JSON.

The API is an enterprise-only feature

Setup

Authentication

Within the Studio's API Keys tab, new API keys can be generated.

To access any of the resources, include the API key as the X-API-KEY header.

To obtain the API specification as an OpenAPI JSON, you can access:

curl https://api.formsort.com/alpha/spec --header "X-API-KEY: {{YOUR API KEY}}"

Pagination

Many endpoints return arrays of objects, with the results in a data array, and a pagination object describing the result set.

{
  "data": [
     ...
  ],
  "pagination": {
    "page": 1,
    "perPage": 10,
    "total": 152
  }
}

You can pass the following URL query parameters to paginate through the results list.

  • page (optional) - integer representing the page number.

  • perPage (optional) - integer representing the number of results per page.

JSON

The API consumes and produces JSON data (application/json). The specific content of the JSON data is described below.

Readonly resources

The following API paths are available at https://api.formsort.com

Obtain specification

GET /alpha/spec

Responses

  • 200 - An OpenAPI 3.0 specification of this API.

List flows

GET /alpha/flows

This path returns a list of Flows.

Responses

  • 200 - A JSON object with a list of Flows at the data key

The shape of the Flow object is:

Flow:
  type: object
  properties:
    label:
      type: string
    createdAt:
      type: string
      format: date-time
  required:
    - createdAt
    - label

List variants for a flow

GET /alpha/flows/{flowLabel}/variants

This path returns a list of Variants for the specified Flow.

Parameters

  • flowLabel (required) - string representing the Flow label.

Responses

  • 200 - A JSON object with a list of Variants within the data key

The shape of a single variant is:

Variant:
  type: object
  properties:
    label:
      type: string
    createdAt:
      type: string
      format: date-time
  required:
    - createdAt
    - label

List environments for a flow

GET /alpha/flows/{flowLabel}/environments

This path returns a list of Environments for the specified flow

Parameters

  • flowLabel (required) - string representing the Flow label.

Responses

  • 200 - A JSON object with a list of Environments within the data key

The shape of the Environment object is:

Environment:
  type: object
  properties:
    revisionUuid:
      type: string
    label:
      type: string
    integrations:
      type: array
      items:
        type: object
        properties:
          type:
            type: string
          configuration:
            type: object
  required:
    - revisionUuid
    - label
    - integrations

List deployments of a particular variant

GET /alpha/flows/{flowLabel}/variants/{variantLabel}/deployments

This path returns a list of Deployments for the specified Variant.

Parameters

  • flowLabel (required) - string representing the Flow label.

  • variantLabel (required) - string representing the Variant label.

Responses

  • 200 - A JSON object with a list of Deployments within the data key

The shape of the Deployment object is:

Deployment:
  type: object
  properties:
    deployedBy:
      type: object
      properties:
        email:
          type: string
      required:
        - email
    deployedAt:
      type: string
      format: date-time
    notes:
      type: string
      nullable: true
    variantRevision:
      type: object
      properties:
        uuid:
          type: string
      required:
        - uuid
    environment:
      "$ref": "#/components/schemas/Environment"
  required:
    - deployedAt
    - deployedBy
    - environment

List available themes

GET /alpha/themes

This path returns the list of themes within the workspace.

Responses

  • 200 A JSON object with the list of Theme at the data key

Themes look like

Theme:
  type: object
  properties:
    label:
      type: string
    createdAt:
      type: string
      format: date-time
    updatedAt:
      type: string
      format: date-time

Get details of a specific variant revision

GET /alpha/variant-revisions/{uuid}

This path returns details of a Variant Revision.

Parameters

  • uuid (required) - string representing the UUID of the Variant Revision.

Responses

  • 200 - A JSON object with details of a Variant Revision at the data key

Body:

  • jsonSchema : The JSON schema describing the answers collected by this revision.

Action resources

Create a new deployment of a variant revision

POST /alpha/deployment

Create a new deployment of a variant revision.

Body

A JSON object with, at the minimum, variantRevisionUuid, environmentRevisionUuid, and isSuperseding.

DeploymentBody:
  type: object
  properties:
    ignoreSupersededAnswers:
      type: boolean
    isSuperseding:
      type: boolean
    notes:
      type: string
    variantRevisionUuid:
      type: string
    environmentRevisionUuid:
      type: string
  required:
    - isSuperseding
    - environmentRevisionUuid
    - variantRevisionUuid

Responses

  • 200 - A JSON object with details of a Variant Revision at the data key.

PreviousRuntime error reportingNextFlow content data format

Last updated 1 year ago

Was this helpful?

flowContent: The describing this revision.

The environmentRevisionUuid can be obtained using the endpoint

๐Ÿ’พ
Flow content
List environments for a flow