Save the lock templates
Content
Resource URL
https://apps.ticketmatic.com/api/1/{accountname}/settings/seatingplans/seatingplans/{id}/locktemplates
Description
Save the lock templates for this seating plan.
Example
Request
1use Ticketmatic\Endpoints\Settings\Seatingplans\Seatingplans;
2
3$result = Seatingplans::savelocktemplates($client, $id, array(
4 array(
5 "name" => "Seating area technicians",
6 "seats" => array(
7 "s001001001" => 1,
8 "s001001002" => 1,
9 ),
10 ),
11));
Request
1import (
2 "github.com/ticketmatic/tm-go/ticketmatic"
3 "github.com/ticketmatic/tm-go/ticketmatic/settings/seatingplans/seatingplans"
4)
5
6result, err := seatingplans.Savelocktemplates(client, id, []*ticketmatic.LockTemplate{
7 &ticketmatic.LockTemplate{
8 Name: "Seating area technicians",
9 Seats: map[string]int64{
10 "s001001001": 1,
11 "s001001002": 1,
12 },
13 },
14})
Request
1POST /api/1/{accountname}/settings/seatingplans/seatingplans/{id}/locktemplates HTTP/1.1
2Content-Type: application/json
3
4[
5 {
6 "name": "Seating area technicians",
7 "seats": {
8 "s001001001": 1.000000,
9 "s001001002": 1.000000
10 }
11 }
12]
Request body fields
This call expects an array of objects in the request body.
Field | Description |
---|---|
name string (required) | The name of the template Example value:"Seating area technicians" |
seats map<string, int> (required) | A map where seat id is the key and the lock type is the value Example value:{ "s001001001": 1.000000, "s001001002": 1.000000 } |
Type reference: LockTemplate[]
Result fields
This call returns an array of objects.
Field | Description |
---|---|
name string | The name of the template Example value:"Seating area technicians" |
seats map<string, int> | A map where seat id is the key and the lock type is the value Example value:{ "s001001001": 1.000000, "s001001002": 1.000000 } |
Type reference: LockTemplate[]