/message_types/{id}
Use this resource to get defails, update, or delete a message_type.
Get message_type details.
Headers
Name | Required | Type | Description |
---|---|---|---|
X-AUTH-TOKEN | * | string |
An authentication token provided to you by GovDelivery. |
Body
Example
{
"code": "salutations",
"label": "Greetings and Salutations",
"_links": {
"self": "/message_type/21768"
}
}
Schema
Name | Type | Description |
---|---|---|
code | string |
The unique identifier Example
|
label | string |
Human readable description. Example
|
_links | object |
An object that defines links to related objects. Properties
|
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Message_Type",
"type": "object",
"properties": {
"code": {
"description": "The unique identifier",
"type": "string",
"example": "salutations"
},
"label": {
"description": "Human readable description.",
"type": "string",
"example": "Greetings and Salutations"
},
"_links": {
"title": "Relational Links",
"description": "An object that defines links to related objects.",
"type": "object",
"properties": {
"self": {
"description": "Relative URI of the object",
"type": "string",
"example": "/message_types/10040"
}
}
}
}
}
Body
Example
{
"error": "Invalid authentication token"
}
Update/modify a label for a Message Type. The code can not be changed.
Headers
Name | Required | Type | Description |
---|---|---|---|
X-AUTH-TOKEN | * | string |
An authentication token provided to you by GovDelivery. |
Body
Example
{
"code": "salutations",
"label": "Greetings and Salutations"
}
Schema
Name | Required | Type | Description |
---|---|---|---|
code | * | string |
The unique identifier Example
|
label | * | string |
Human readable description Example
|
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "/message_types/{id}",
"description": "Update/modify a label for a Message Type. The code can not be changed.",
"type": "object",
"properties": {
"code": {
"description": "The unique identifier\n",
"type": "string",
"example": "salutations"
},
"label": {
"description": "Human readable description\n",
"type": "string",
"example": "Greetings and Salutations"
}
},
"required": [
"code",
"label"
]
}
Form Parameters
Name | Required | Type | Description |
---|---|---|---|
code | * | string |
The unique identifier Example
|
label | * | string |
Human readable description Example
|
Description
The updated Message Type object
Body
Example
{
"code": "salutations",
"label": "Greetings and Salutations",
"_links": {
"self": "/message_type/21768"
}
}
Schema
Name | Type | Description |
---|---|---|
code | string |
The unique identifier Example
|
label | string |
Human readable description. Example
|
_links | object |
An object that defines links to related objects. Properties
|
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Message_Type",
"type": "object",
"properties": {
"code": {
"description": "The unique identifier",
"type": "string",
"example": "salutations"
},
"label": {
"description": "Human readable description.",
"type": "string",
"example": "Greetings and Salutations"
},
"_links": {
"title": "Relational Links",
"description": "An object that defines links to related objects.",
"type": "object",
"properties": {
"self": {
"description": "Relative URI of the object",
"type": "string",
"example": "/message_types/10040"
}
}
}
}
}
Body
Example
{
"error": "Invalid authentication token"
}
Delete a message_type. Message Types can only be deleted if they are not yet associated with any sent messages
Headers
Name | Required | Type | Description |
---|---|---|---|
X-AUTH-TOKEN | * | string |
An authentication token provided to you by GovDelivery. |
Description
The Message Type was successfully deleted.
Description
An Email Message was created with this Message Type so it can not be deleted.
Body
Example
{
"error": "Invalid authentication token"
}