Save packet template
POST
/packet-constructor/templatesValidates and compiles the packet template and saves it to the shared library. Template errors are returned as a list in data.issues with paths to the fields.
Contract
Parameter | Value |
|---|---|
| Section | packet-constructor |
| Authentication | CookieAuth |
| Consumes | application/json |
| Produces | application/json |
Parameters
1 parameter
Name | Location | Required | Type | Description |
|---|---|---|---|---|
| request | body | yes | object | Name, description, and packet template |
{ "description": "<string>", "name": "<string>", "template": {} }
Responses
5 responses
Status | Description | Type |
|---|---|---|
201 | Response: {data: <new template ID>} | object |
400 | Invalid request body, metadata, or template; template errors are listed in data.issues[]{path, message} | object |
401 | Unauthorized | object |
413 | Request body exceeds 8 MiB | object |
500 | Internal server error | object |
{}{ "data": {}, "error": "<string>" }{ "data": {}, "error": "<string>" }{ "data": {}, "error": "<string>" }{ "data": {}, "error": "<string>" }