Skip to main content

Class: ApiKeySpec

identity.v1.ApiKeySpec

Represents an ApiKeySpec.

Properties​

description​

• description: string

The description of the API key.


disabled​

• disabled: boolean

True if the API key is disabled.


displayName​

• displayName: string

The display name of the API key.


expiryTime​

• Optional expiryTime: null | $Properties

The expiry time of the API key.


ownerId​

• ownerId: string

The id of the owner to create the API key for. The owner id is immutable. Once set during creation, it cannot be changed. The owner id is the id of the user when the owner type is user. The owner id is the id of the service account when the owner type is service account.


ownerType​

• ownerType: OwnerType

The type of the owner to create the API key for. temporal:versioning:min_version=v0.3.0 temporal:enums:replaces=owner_type_deprecated


ownerTypeDeprecated​

• ownerTypeDeprecated: string

The type of the owner to create the API key for. The owner type is immutable. Once set during creation, it cannot be changed. Possible values: user, service-account. Deprecated: Not supported after v0.3.0 api version. Use owner_type instead. temporal:versioning:max_version=v0.3.0

Methods​

toJSON​

▸ toJSON(): Object

Converts this ApiKeySpec to JSON.

Returns​

Object

JSON object


create​

▸ create(properties?): ApiKeySpec & $Properties

Creates a new ApiKeySpec instance using the specified properties.

Parameters​

NameTypeDescription
properties?$PropertiesProperties to set

Returns​

ApiKeySpec & $Properties

ApiKeySpec instance

▸ create(properties?): ApiKeySpec

Parameters​

NameType
properties?$Properties

Returns​

ApiKeySpec


decode​

▸ decode(reader, length?): ApiKeySpec & $Properties

Decodes an ApiKeySpec message from the specified reader or buffer.

Parameters​

NameTypeDescription
readerUint8Array | ReaderReader or buffer to decode from
length?numberMessage length if known beforehand

Returns​

ApiKeySpec & $Properties

ApiKeySpec

Throws

If the payload is not a reader or valid buffer

Throws

If required fields are missing


decodeDelimited​

▸ decodeDelimited(reader): ApiKeySpec & $Properties

Decodes an ApiKeySpec message from the specified reader or buffer, length delimited.

Parameters​

NameTypeDescription
readerUint8Array | ReaderReader or buffer to decode from

Returns​

ApiKeySpec & $Properties

ApiKeySpec

Throws

If the payload is not a reader or valid buffer

Throws

If required fields are missing


encode​

▸ encode(message, writer?): Writer

Encodes the specified ApiKeySpec message. Does not implicitly temporal.api.cloud.identity.v1.ApiKeySpec.verify|verify messages.

Parameters​

NameTypeDescription
message$PropertiesApiKeySpec message or plain object to encode
writer?WriterWriter to encode to

Returns​

Writer

Writer


encodeDelimited​

▸ encodeDelimited(message, writer?): Writer

Encodes the specified ApiKeySpec message, length delimited. Does not implicitly temporal.api.cloud.identity.v1.ApiKeySpec.verify|verify messages.

Parameters​

NameTypeDescription
message$PropertiesApiKeySpec message or plain object to encode
writer?WriterWriter to encode to

Returns​

Writer

Writer


fromObject​

▸ fromObject(object): ApiKeySpec

Creates an ApiKeySpec message from a plain object. Also converts values to their respective internal types.

Parameters​

NameTypeDescription
objectObjectPlain object

Returns​

ApiKeySpec

ApiKeySpec


toObject​

▸ toObject(message, options?): Object

Creates a plain object from an ApiKeySpec message. Also converts values to other types if specified.

Parameters​

NameTypeDescription
messageApiKeySpecApiKeySpec
options?IConversionOptionsConversion options

Returns​

Object

Plain object