IoTThingsGraph / Client / create_flow_template

create_flow_template#

IoTThingsGraph.Client.create_flow_template(**kwargs)#

Creates a workflow template. Workflows can be created only in the user’s namespace. (The public namespace contains only entities.) The workflow can contain only entities in the specified namespace. The workflow is validated against the entities in the latest version of the user’s namespace unless another namespace version is specified in the request.

Danger

This operation is deprecated and may not function as expected. This operation should not be used going forward and is only kept for the purpose of backwards compatiblity.

See also: AWS API Documentation

Request Syntax

response = client.create_flow_template(
    definition={
        'language': 'GRAPHQL',
        'text': 'string'
    },
    compatibleNamespaceVersion=123
)
Parameters:
  • definition (dict) –

    [REQUIRED]

    The workflow DefinitionDocument.

    • language (string) – [REQUIRED]

      The language used to define the entity. GRAPHQL is the only valid value.

    • text (string) – [REQUIRED]

      The GraphQL text that defines the entity.

  • compatibleNamespaceVersion (integer) –

    The namespace version in which the workflow is to be created.

    If no value is specified, the latest version is used by default.

Return type:

dict

Returns:

Response Syntax

{
    'summary': {
        'id': 'string',
        'arn': 'string',
        'revisionNumber': 123,
        'createdAt': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) –

    • summary (dict) –

      The summary object that describes the created workflow.

      • id (string) –

        The ID of the workflow.

      • arn (string) –

        The ARN of the workflow.

      • revisionNumber (integer) –

        The revision number of the workflow.

      • createdAt (datetime) –

        The date when the workflow was created.

Exceptions

  • IoTThingsGraph.Client.exceptions.InvalidRequestException

  • IoTThingsGraph.Client.exceptions.ResourceAlreadyExistsException

  • IoTThingsGraph.Client.exceptions.ThrottlingException

  • IoTThingsGraph.Client.exceptions.LimitExceededException

  • IoTThingsGraph.Client.exceptions.InternalFailureException