Make a duplicate of an existing form

POST /api/v1/form/{form_uuid}/duplicate

Headers

Path parameters

Responses

  • 201 application/json
    Hide response attributes Show response attributes object
    • uuid string

      The UUID of the resource.

    • The timestamp of when the resource was created.

    • The timestamp of when the resource was updated.

    • title string

      The title of the form

    • The description of the form

    • live boolean

      Whether the form is live

    • The visibility of the form

    • sections object

      The sections of the form. They include the forms questions in a array

      Additional properties are allowed.

    • allowed_hosts array[string]

      Array of allowed domains that this form can be accessed from using different origins

    • Count of draft submissions against this form

    • Count of submitted submissions against this form

    • Denotes if this form creates a new client when it is submitted from a public embed

    • If create_client is true, then the client_type is the type of client that will be created, possible values are client and prospect

POST /api/v1/form/{form_uuid}/duplicate
curl \
 -X POST https://api.plannrcrm.com/api/v1/form/form_uuid/duplicate \
 -H "Authorization: Bearer {OAUTH_ACCESS_TOKEN or PERSONAL_ACCESS_TOKEN}" \
 -H "Content-Type: application/json" \
 -H "Accept: application/json" \
 -H "X-PLANNR-ACCOUNT-UUID: {YOUR_PLANNR_ACCOUNT_UUID}"
Response examples (201)
{
  "live": true,
  "uuid": "5adb9ff5-ff8d-45ea-abe5-30318573f183",
  "title": "Annual Catchup 2022",
  "sections": {
    "key": "what_is_your_name",
    "type": "string",
    "uuid": "621d476e-3c40-467a-a3bc-4a937a24a6d0",
    "title": "What is your name?",
    "caption": "Your full legal name",
    "section": "App\\Http\\Resources\\FormSectionResource",
    "position": 1,
    "required": true,
    "help_text": "Gareth",
    "created_at": "2024-11-20T13:24:01+00:00",
    "updated_at": "2024-11-20T13:24:01+00:00",
    "target_field": "name",
    "linked_primary": true,
    "linked_question": "App\\Http\\Resources\\FormBuilder\\LinkedFormQuestionResource",
    "selection_options": [
      "option 1",
      "option 2"
    ]
  },
  "created_at": "2024-11-20T13:24:01+00:00",
  "updated_at": "2024-11-20T13:24:01+00:00",
  "visibility": "public",
  "client_type": "client",
  "description": "This is the annual catchup form for 2022",
  "allowed_hosts": [
    "domain.com",
    "subdomain.domain.com"
  ],
  "create_client": true,
  "draft_submissions_count": 5,
  "submitted_submissions_count": 5
}