content_types
Creates, updates, deletes, gets or lists a content_types
resource.
Overview
Name | content_types |
Type | Resource |
Id | azure.api_management.content_types |
Fields
The following fields are returned by SELECT
queries:
- get
- list_by_service
Returns the details of the specified content type.
Name | Datatype | Description |
---|---|---|
properties | object | Properties of the content type. |
Returns a collection of the Content Type entities.
Name | Datatype | Description |
---|---|---|
properties | object | Properties of the content type. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | resourceGroupName , serviceName , contentTypeId , subscriptionId | Gets the details of the developer portal's content type. Content types describe content items' properties, validation rules, and constraints. | |
list_by_service | select | resourceGroupName , serviceName , subscriptionId | Lists the developer portal's content types. Content types describe content items' properties, validation rules, and constraints. | |
create_or_update | insert | resourceGroupName , serviceName , contentTypeId , subscriptionId | If-Match | Creates or updates the developer portal's content type. Content types describe content items' properties, validation rules, and constraints. Custom content types' identifiers need to start with the c- prefix. Built-in content types can't be modified. |
delete | delete | resourceGroupName , serviceName , contentTypeId , If-Match , subscriptionId | Removes the specified developer portal's content type. Content types describe content items' properties, validation rules, and constraints. Built-in content types (with identifiers starting with the c- prefix) can't be removed. |
Parameters
Parameters can be passed in the WHERE
clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
Name | Datatype | Description |
---|---|---|
If-Match | string | ETag of the Entity. ETag should match the current entity state from the header response of the GET request or it should be * for unconditional update. |
contentTypeId | string | Content type identifier. |
resourceGroupName | string | The name of the resource group. The name is case insensitive. |
serviceName | string | The name of the API Management service. |
subscriptionId | string | The ID of the target subscription. |
If-Match | string | ETag of the Entity. Not required when creating an entity, but required when updating an entity. |
SELECT
examples
- get
- list_by_service
Gets the details of the developer portal's content type. Content types describe content items' properties, validation rules, and constraints.
SELECT
properties
FROM azure.api_management.content_types
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND serviceName = '{{ serviceName }}' -- required
AND contentTypeId = '{{ contentTypeId }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
;
Lists the developer portal's content types. Content types describe content items' properties, validation rules, and constraints.
SELECT
properties
FROM azure.api_management.content_types
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND serviceName = '{{ serviceName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
;
INSERT
examples
- create_or_update
- Manifest
Creates or updates the developer portal's content type. Content types describe content items' properties, validation rules, and constraints. Custom content types' identifiers need to start with the c-
prefix. Built-in content types can't be modified.
INSERT INTO azure.api_management.content_types (
data__properties,
resourceGroupName,
serviceName,
contentTypeId,
subscriptionId,
If-Match
)
SELECT
'{{ properties }}',
'{{ resourceGroupName }}',
'{{ serviceName }}',
'{{ contentTypeId }}',
'{{ subscriptionId }}',
'{{ If-Match }}'
RETURNING
properties
;
# Description fields are for documentation purposes
- name: content_types
props:
- name: resourceGroupName
value: string
description: Required parameter for the content_types resource.
- name: serviceName
value: string
description: Required parameter for the content_types resource.
- name: contentTypeId
value: string
description: Required parameter for the content_types resource.
- name: subscriptionId
value: string
description: Required parameter for the content_types resource.
- name: properties
value: object
description: |
Properties of the content type.
- name: If-Match
value: string
description: ETag of the Entity. Not required when creating an entity, but required when updating an entity.
DELETE
examples
- delete
Removes the specified developer portal's content type. Content types describe content items' properties, validation rules, and constraints. Built-in content types (with identifiers starting with the c-
prefix) can't be removed.
DELETE FROM azure.api_management.content_types
WHERE resourceGroupName = '{{ resourceGroupName }}' --required
AND serviceName = '{{ serviceName }}' --required
AND contentTypeId = '{{ contentTypeId }}' --required
AND If-Match = '{{ If-Match }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
;