Input fields

List all input fields

GET /fast-events/v1/admin/events/(integer: id)/input-fields

List all input fields of the selected event. If is_personalised is false, the input field is used on the order level. Users need to fill it in when ordering.

If the value is true, each ticket must be personalised after ordering. You cannot download tickets unless all tickets are personalised.

Optional query parameters

_fields

A comma separated string of fields included in the response. For example name,type.

Example request

$ curl \
  -H "X-FE-API-KEY: 3zo58AUYP9zOE6YT"  \
  -H "Content-Type: application/json" \
  -u "test:4ZAN O5OY OAvZ FZb2 Lslv JnJG" \
  https://exampledomain.com/wp-json/fast-events/v1/admin/events/54/input-fields

Example response

[
    {
        "id": "v0f446",
        "name": "Country",
        "type": "text",
        "value": "France",
        "min": "",
        "max": "30",
        "is_required": false,
        "is_personalised": false,
        "_links": {
            "self": [
                {
                    "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields/v0f446"
                }
            ],
            "collection": [
                {
                    "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields"
                }
            ]
        }
    },
    {
        "id": "v19e73",
        "name": "Public transport",
        "type": "select",
        "value": "Yes,No",
        "min": "",
        "max": "30",
        "is_required": true,
        "is_personalised": false,
        "_links": {
            "self": [
                {
                    "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields/v19e73"
                }
            ],
            "collection": [
                {
                    "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields"
                }
            ]
        }
    }
]

Changelog

Version

Description

1.0

Introduced.

2.1.0

Added min, max and is_personalised.


List input field

GET /fast-events/v1/admin/events/(integer: id)/input-fields/(input_field)

Retrieve details of a single input field.

Query parameters

_fields

A comma separated string of fields included in the response. For example name,type.

Example request

$ curl \
  -H "X-FE-API-KEY: 3zo58AUYP9zOE6YT"  \
  -H "Content-Type: application/json" \
  -u "test:4ZAN O5OY OAvZ FZb2 Lslv JnJG" \
  https://exampledomain.com/wp-json/fast-events/v1/admin/events/54/input-fields/v0f446

Example response

{
    "id": "v0f446",
    "name": "Country",
    "type": "text",
    "value": "France",
    "min": "",
    "max": "30",
    "is_required": false,
    "is_personalised": false,
    "_links": {
        "self": [
            {
                "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields/v0f446"
            }
        ],
        "collection": [
            {
                "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields"
            }
        ]
    }
}

Changelog

Version

Description

1.0

Introduced.

2.1.0

Added min, max and is_personalised.


Update input field

PUT /fast-events/v1/admin/events/(integer: id)/input-fields/(input_field)

Update a input field.

Example request

$ curl \
  -X PUT \
  -H "X-FE-API-KEY: 3zo58AUYP9zOE6YT"  \
  -H "Content-Type: application/json" \
  -u "test:4ZAN O5OY OAvZ FZb2 Lslv JnJG" \
  -d '{"value": "Netherlands"}' \
  https://exampledomain.com/wp-json/fast-events/v1/admin/events/54/input-fields/v0f446

Example response

{
    "name": "Country",
    "type": "text",
    "value": "Netherlands",
    "min": "",
    "max": "30",
    "is_required": false,
    "is_personalised": false,
    "_links": {
        "self": [
            {
                "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields/v0f446"
            }
        ],
        "collection": [
            {
                "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields"
            }
        ]
    }
}

Changelog

Version

Description

1.0

Introduced.

2.1

Added min, max and is_personalised.


Delete input field

DELETE /fast-events/v1/admin/events/(integer: id)/input-fields/(input_field)

Delete a single input field.

Example request

$ curl \
  -X DELETE \
  -H "X-FE-API-KEY: 3zo58AUYP9zOE6YT"  \
  -H "Content-Type: application/json" \
  -u "test:4ZAN O5OY OAvZ FZb2 Lslv JnJG" \
  https://exampledomain.com/wp-json/fast-events/v1/admin/events/54/input-fields/v0f446

Example response

{
    "deleted": true,
    "previous": {
        "name": "Country",
        "type": "text",
        "value": "Netherlands",
        "min": "",
        "max": "30",
        "is_required": false,
        "is_personalised": false,
    }
}

Changelog

Version

Description

1.0

Introduced.

2.1

Added min, max and is_personalised.


Create input field

POST /fast-events/v1/admin/events/(integer: id)/input-fields

Create a new input field.

Example request

$ curl \
  -X POST \
  -H "X-FE-API-KEY: 3zo58AUYP9zOE6YT"  \
  -H "Content-Type: application/json" \
  -u "test:4ZAN O5OY OAvZ FZb2 Lslv JnJG" \
  -d '{"name":"Country"}' \
  https://exampledomain.com/wp-json/fast-events/v1/admin/events/54/input-fields

Example response

{
    "id": "v3f5e6",
    "name": "Country",
    "type": "text",
    "value": "",
    "min": "",
    "max": "",
    "is_required": false,
    "is_personalised": false,
    "_links": {
        "self": [
            {
                "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields/v3f5e6"
            }
        ],
        "collection": [
            {
                "href": "https://vinyl-openair.com/wp-json/fast-events/v1/admin/events/54/input-fields"
            }
        ]
    }
}

Changelog

Version

Description

1.0

Introduced.

2.1

Added min, max and is_personalised.