Amazon Interactive Video Service RealTime

2023/03/23 - Amazon Interactive Video Service RealTime - 10 new api methods

Changes  Initial release of the Amazon Interactive Video Service RealTime API.

DisconnectParticipant (new) Link ¶

Disconnects a specified participant and revokes the participant permanently from a specified stage.

See also: AWS API Documentation

Request Syntax

client.disconnect_participant(
    participantId='string',
    reason='string',
    stageArn='string'
)
type participantId

string

param participantId

[REQUIRED]

Identifier of the participant to be disconnected. This is returned by CreateParticipantToken .

type reason

string

param reason

Description of why this participant is being disconnected.

type stageArn

string

param stageArn

[REQUIRED]

ARN of the stage to which the participant is attached.

rtype

dict

returns

Response Syntax

{}

Response Structure

  • (dict) --

CreateParticipantToken (new) Link ¶

Creates an additional token for a specified stage. This can be done after stage creation or when tokens expire. Tokens always are scoped to the stage for which they are created.

Encryption keys are owned by Amazon IVS and never used directly by your application.

See also: AWS API Documentation

Request Syntax

client.create_participant_token(
    attributes={
        'string': 'string'
    },
    capabilities=[
        'PUBLISH'|'SUBSCRIBE',
    ],
    duration=123,
    stageArn='string',
    userId='string'
)
type attributes

dict

param attributes

Application-provided attributes to encode into the token and attach to a stage. Map keys and values can contain UTF-8 encoded text. The maximum length of this field is 1 KB total. This field is exposed to all stage participants and should not be used for personally identifying, confidential, or sensitive information.

  • (string) --

    • (string) --

type capabilities

list

param capabilities

Set of capabilities that the user is allowed to perform in the stage. Default: PUBLISH, SUBSCRIBE .

  • (string) --

type duration

integer

param duration

Duration (in minutes), after which the token expires. Default: 60 (1 hour).

type stageArn

string

param stageArn

[REQUIRED]

ARN of the stage to which this token is scoped.

type userId

string

param userId

Name that can be specified to help identify the token. This can be any UTF-8 encoded text. This field is exposed to all stage participants and should not be used for personally identifying, confidential, or sensitive information.

rtype

dict

returns

Response Syntax

{
    'participantToken': {
        'attributes': {
            'string': 'string'
        },
        'capabilities': [
            'PUBLISH'|'SUBSCRIBE',
        ],
        'duration': 123,
        'expirationTime': datetime(2015, 1, 1),
        'participantId': 'string',
        'token': 'string',
        'userId': 'string'
    }
}

Response Structure

  • (dict) --

    • participantToken (dict) --

      The participant token that was created.

      • attributes (dict) --

        Application-provided attributes to encode into the token and attach to a stage. This field is exposed to all stage participants and should not be used for personally identifying, confidential, or sensitive information.

        • (string) --

          • (string) --

      • capabilities (list) --

        Set of capabilities that the user is allowed to perform in the stage.

        • (string) --

      • duration (integer) --

        Duration (in minutes), after which the participant token expires. Default: 60 (1 hour).

      • expirationTime (datetime) --

        ISO 8601 timestamp (returned as a string) for when this token expires.

      • participantId (string) --

        Unique identifier for this participant token, assigned by IVS.

      • token (string) --

        The issued client token, encrypted.

      • userId (string) --

        Name to help identify the token. This can be any UTF-8 encoded text. This field is exposed to all stage participants and should not be used for personally identifying, confidential, or sensitive information.

UntagResource (new) Link ¶

Removes tags from the resource with the specified ARN.

See also: AWS API Documentation

Request Syntax

client.untag_resource(
    resourceArn='string',
    tagKeys=[
        'string',
    ]
)
type resourceArn

string

param resourceArn

[REQUIRED]

The ARN of the resource to be untagged. The ARN must be URL-encoded.

type tagKeys

list

param tagKeys

[REQUIRED]

Array of tags to be removed. Array of maps, each of the form string:string (key:value) . See Tagging AWS Resources for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints beyond what is documented there.

  • (string) --

rtype

dict

returns

Response Syntax

{}

Response Structure

  • (dict) --

UpdateStage (new) Link ¶

Updates a stage’s configuration.

See also: AWS API Documentation

Request Syntax

client.update_stage(
    arn='string',
    name='string'
)
type arn

string

param arn

[REQUIRED]

ARN of the stage to be updated.

type name

string

param name

Name of the stage to be updated.

rtype

dict

returns

Response Syntax

{
    'stage': {
        'activeSessionId': 'string',
        'arn': 'string',
        'name': 'string',
        'tags': {
            'string': 'string'
        }
    }
}

Response Structure

  • (dict) --

    • stage (dict) --

      The updated stage.

      • activeSessionId (string) --

        ID of the active session within the stage.

      • arn (string) --

        Stage ARN.

      • name (string) --

        Stage name.

      • tags (dict) --

        Tags attached to the resource. Array of maps, each of the form string:string (key:value) . See Tagging AWS Resources for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints on tags beyond what is documented there.

        • (string) --

          • (string) --

ListTagsForResource (new) Link ¶

Gets information about AWS tags for the specified ARN.

See also: AWS API Documentation

Request Syntax

client.list_tags_for_resource(
    resourceArn='string'
)
type resourceArn

string

param resourceArn

[REQUIRED]

The ARN of the resource to be retrieved. The ARN must be URL-encoded.

rtype

dict

returns

Response Syntax

{
    'tags': {
        'string': 'string'
    }
}

Response Structure

  • (dict) --

    • tags (dict) --

      Tags attached to the resource. Array of maps, each of the form string:string (key:value) .

      • (string) --

        • (string) --

CreateStage (new) Link ¶

Creates a new stage (and optionally participant tokens).

See also: AWS API Documentation

Request Syntax

client.create_stage(
    name='string',
    participantTokenConfigurations=[
        {
            'attributes': {
                'string': 'string'
            },
            'capabilities': [
                'PUBLISH'|'SUBSCRIBE',
            ],
            'duration': 123,
            'userId': 'string'
        },
    ],
    tags={
        'string': 'string'
    }
)
type name

string

param name

Optional name that can be specified for the stage being created.

type participantTokenConfigurations

list

param participantTokenConfigurations

Array of participant token configuration objects to attach to the new stage.

  • (dict) --

    Object specifying a participant token configuration in a stage.

    • attributes (dict) --

      Application-provided attributes to encode into the corresponding participant token and attach to a stage. Map keys and values can contain UTF-8 encoded text. The maximum length of this field is 1 KB total. This field is exposed to all stage participants and should not be used for personally identifying, confidential, or sensitive information.

      • (string) --

        • (string) --

    • capabilities (list) --

      Set of capabilities that the user is allowed to perform in the stage.

      • (string) --

    • duration (integer) --

      Duration (in minutes), after which the corresponding participant token expires. Default: 60 (1 hour).

    • userId (string) --

      Name that can be specified to help identify the corresponding participant token. This can be any UTF-8 encoded text. This field is exposed to all stage participants and should not be used for personally identifying, confidential, or sensitive information.

type tags

dict

param tags

Tags attached to the resource. Array of maps, each of the form string:string (key:value) . See Tagging AWS Resources for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints on tags beyond what is documented there.

  • (string) --

    • (string) --

rtype

dict

returns

Response Syntax

{
    'participantTokens': [
        {
            'attributes': {
                'string': 'string'
            },
            'capabilities': [
                'PUBLISH'|'SUBSCRIBE',
            ],
            'duration': 123,
            'expirationTime': datetime(2015, 1, 1),
            'participantId': 'string',
            'token': 'string',
            'userId': 'string'
        },
    ],
    'stage': {
        'activeSessionId': 'string',
        'arn': 'string',
        'name': 'string',
        'tags': {
            'string': 'string'
        }
    }
}

Response Structure

  • (dict) --

    • participantTokens (list) --

      Participant tokens attached to the stage. These correspond to the participants in the request.

      • (dict) --

        Object specifying a participant token in a stage.

        • attributes (dict) --

          Application-provided attributes to encode into the token and attach to a stage. This field is exposed to all stage participants and should not be used for personally identifying, confidential, or sensitive information.

          • (string) --

            • (string) --

        • capabilities (list) --

          Set of capabilities that the user is allowed to perform in the stage.

          • (string) --

        • duration (integer) --

          Duration (in minutes), after which the participant token expires. Default: 60 (1 hour).

        • expirationTime (datetime) --

          ISO 8601 timestamp (returned as a string) for when this token expires.

        • participantId (string) --

          Unique identifier for this participant token, assigned by IVS.

        • token (string) --

          The issued client token, encrypted.

        • userId (string) --

          Name to help identify the token. This can be any UTF-8 encoded text. This field is exposed to all stage participants and should not be used for personally identifying, confidential, or sensitive information.

    • stage (dict) --

      The stage that was created.

      • activeSessionId (string) --

        ID of the active session within the stage.

      • arn (string) --

        Stage ARN.

      • name (string) --

        Stage name.

      • tags (dict) --

        Tags attached to the resource. Array of maps, each of the form string:string (key:value) . See Tagging AWS Resources for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints on tags beyond what is documented there.

        • (string) --

          • (string) --

ListStages (new) Link ¶

Gets summary information about all stages in your account, in the AWS region where the API request is processed.

See also: AWS API Documentation

Request Syntax

client.list_stages(
    maxResults=123,
    nextToken='string'
)
type maxResults

integer

param maxResults

Maximum number of results to return. Default: 50.

type nextToken

string

param nextToken

The first stage to retrieve. This is used for pagination; see the nextToken response field.

rtype

dict

returns

Response Syntax

{
    'nextToken': 'string',
    'stages': [
        {
            'activeSessionId': 'string',
            'arn': 'string',
            'name': 'string',
            'tags': {
                'string': 'string'
            }
        },
    ]
}

Response Structure

  • (dict) --

    • nextToken (string) --

      If there are more rooms than maxResults , use nextToken in the request to get the next set.

    • stages (list) --

      List of the matching stages (summary information only).

      • (dict) --

        Summary information about a stage.

        • activeSessionId (string) --

          ID of the active session within the stage.

        • arn (string) --

          Stage ARN.

        • name (string) --

          Stage name.

        • tags (dict) --

          Tags attached to the resource. Array of maps, each of the form string:string (key:value) . See Tagging AWS Resources for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints on tags beyond what is documented there.

          • (string) --

            • (string) --

DeleteStage (new) Link ¶

Shuts down and deletes the specified stage (disconnecting all participants).

See also: AWS API Documentation

Request Syntax

client.delete_stage(
    arn='string'
)
type arn

string

param arn

[REQUIRED]

ARN of the stage to be deleted.

rtype

dict

returns

Response Syntax

{}

Response Structure

  • (dict) --

TagResource (new) Link ¶

Adds or updates tags for the AWS resource with the specified ARN.

See also: AWS API Documentation

Request Syntax

client.tag_resource(
    resourceArn='string',
    tags={
        'string': 'string'
    }
)
type resourceArn

string

param resourceArn

[REQUIRED]

The ARN of the resource to be tagged. The ARN must be URL-encoded.

type tags

dict

param tags

[REQUIRED]

Array of tags to be added or updated. Array of maps, each of the form string:string (key:value) . See Tagging AWS Resources for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints beyond what is documented there.

  • (string) --

    • (string) --

rtype

dict

returns

Response Syntax

{}

Response Structure

  • (dict) --

GetStage (new) Link ¶

Gets information for the specified stage.

See also: AWS API Documentation

Request Syntax

client.get_stage(
    arn='string'
)
type arn

string

param arn

[REQUIRED]

ARN of the stage for which the information is to be retrieved.

rtype

dict

returns

Response Syntax

{
    'stage': {
        'activeSessionId': 'string',
        'arn': 'string',
        'name': 'string',
        'tags': {
            'string': 'string'
        }
    }
}

Response Structure

  • (dict) --

    • stage (dict) --

      • activeSessionId (string) --

        ID of the active session within the stage.

      • arn (string) --

        Stage ARN.

      • name (string) --

        Stage name.

      • tags (dict) --

        Tags attached to the resource. Array of maps, each of the form string:string (key:value) . See Tagging AWS Resources for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints on tags beyond what is documented there.

        • (string) --

          • (string) --