All endpoints

Developers / StrawPoll API / Codes and invites

Change an invite

PATCH/forms/{slug}/invites/{id}

Replaces the invite's name, email and code: a name or code you leave out is removed, so send the current values with your change. email is required, so codes without an email cannot be changed here. weight stays as it is when left out.

Needs an API key.

Parameters

Path

  • slug string required max. 20

    The form's public id, as in https://strawpoll.com/r/{slug}.

  • id string (uuid) required

Request body application/json

  • name string
  • email string (email) required
  • code string
  • weight number

    How many times this person's answers count.

    Default: 1

Responses

The invite.

  • id string (uuid)
  • formId string (uuid)
  • inviteListId string (uuid) | null
  • type string

    manual for unique codes.

    One of: email manual

  • name string | null
  • email string | null
  • phone string | null
  • code string | null
  • invited boolean

    Whether the invite was emailed.

  • weight number

    How many times this person's answers count.

  • responseId string (uuid) | null

    Always null in a secret ballot.

  • createdAt string (date-time)
  • respondedAt string (date-time) | null

    Always null in a secret ballot.

  • responded boolean

    Whether the invite or code was used. Not on newly created ones.

Try it

Create a key

Sent from your browser straight to the API, nowhere else. With “Remember” on it stays until you close this tab. A read-only key lets you look around without changing anything.

PATCH https://new.strawpoll.com/api/v4/forms/{slug}/invites/{id}

Paste an API key to send requests that need one.

Requests with a key count against your plan’s daily API requests.