Transaction Action of GS2-Inbox
Specification of verify/consume/acquire transaction actions
ConsumeAction
Gs2Inbox:OpenMessageByUserId
Marking messages as opened by specifying a user ID
Whether the action allows quantity specification: NO
Whether the action is reversible: NO
| Type | Condition | Required | Default | Value Limits | Description | |
|---|---|---|---|---|---|---|
| namespaceName | string | ✓ | ~ 128 chars | Namespace name Namespace-specific name. Specified using alphanumeric characters, hyphens (-), underscores (_), and periods (.). | ||
| userId | string | ✓ | ~ 128 chars | User ID Set #{userId} to replace the currently logged in user ID. | ||
| messageName | string | ✓ | UUID | ~ 36 chars | Message Name Maintains a unique name for each message. Names are automatically generated in UUID (Universally Unique Identifier) format and used to identify each message. | |
| timeOffsetToken | string | ~ 1024 chars | Time offset token |
{
"action": "Gs2Inbox:OpenMessageByUserId",
"request": {
"namespaceName": "[string]Namespace name",
"userId": "[string]User ID",
"messageName": "[string]Message Name",
"timeOffsetToken": "[string]Time offset token"
}
}action: Gs2Inbox:OpenMessageByUserId
request:
namespaceName: "[string]Namespace name"
userId: "[string]User ID"
messageName: "[string]Message Name"
timeOffsetToken: "[string]Time offset token"transaction.service("inbox").consume.open_message_by_user_id({
namespaceName="[string]Namespace name",
userId="[string]User ID",
messageName="[string]Message Name",
timeOffsetToken="[string]Time offset token",
})Gs2Inbox:DeleteMessageByUserId
Delete message by specifying a user ID
Whether the action allows quantity specification: NO
Whether the action is reversible: NO
| Type | Condition | Required | Default | Value Limits | Description | |
|---|---|---|---|---|---|---|
| namespaceName | string | ✓ | ~ 128 chars | Namespace name Namespace-specific name. Specified using alphanumeric characters, hyphens (-), underscores (_), and periods (.). | ||
| userId | string | ✓ | ~ 128 chars | User ID Set #{userId} to replace the currently logged in user ID. | ||
| messageName | string | ✓ | UUID | ~ 36 chars | Message Name Maintains a unique name for each message. Names are automatically generated in UUID (Universally Unique Identifier) format and used to identify each message. | |
| timeOffsetToken | string | ~ 1024 chars | Time offset token |
{
"action": "Gs2Inbox:DeleteMessageByUserId",
"request": {
"namespaceName": "[string]Namespace name",
"userId": "[string]User ID",
"messageName": "[string]Message Name",
"timeOffsetToken": "[string]Time offset token"
}
}action: Gs2Inbox:DeleteMessageByUserId
request:
namespaceName: "[string]Namespace name"
userId: "[string]User ID"
messageName: "[string]Message Name"
timeOffsetToken: "[string]Time offset token"transaction.service("inbox").consume.delete_message_by_user_id({
namespaceName="[string]Namespace name",
userId="[string]User ID",
messageName="[string]Message Name",
timeOffsetToken="[string]Time offset token",
})AcquireAction
Gs2Inbox:SendMessageByUserId
Send a message by specifying a user ID
Whether the action allows quantity specification: NO
Whether the action is reversible: NO
| Type | Condition | Required | Default | Value Limits | Description | |
|---|---|---|---|---|---|---|
| namespaceName | string | ✓ | ~ 128 chars | Namespace name Namespace-specific name. Specified using alphanumeric characters, hyphens (-), underscores (_), and periods (.). | ||
| userId | string | ✓ | ~ 128 chars | User ID Set #{userId} to replace the currently logged in user ID. | ||
| metadata | string | ✓ | ~ 4096 chars | Metadata corresponding to the content of the message | ||
| readAcquireActions | List<AcquireAction> | [] | 0 ~ 100 items | Acquire action to execute when message is opened | ||
| expiresAt | long | Datetime of ttl Unix time, milliseconds | ||||
| expiresTimeSpan | TimeSpan | The period from the time a message was received (reference time) until it was deleted | ||||
| timeOffsetToken | string | ~ 1024 chars | Time offset token |
{
"action": "Gs2Inbox:SendMessageByUserId",
"request": {
"namespaceName": "[string]Namespace name",
"userId": "[string]User ID",
"metadata": "[string]Metadata corresponding to the content of the message",
"readAcquireActions": [
{
"action": "[string]Types of actions to be performed in the acquire action",
"request": "[string]JSON string of the request used when executing the action"
}
],
"expiresAt": "[long]Datetime of ttl",
"expiresTimeSpan": {
"days": "[int]Number of days from the reference time",
"hours": "[int]Hours from the reference time",
"minutes": "[int]Minutes from the reference time"
},
"timeOffsetToken": "[string]Time offset token"
}
}action: Gs2Inbox:SendMessageByUserId
request:
namespaceName: "[string]Namespace name"
userId: "[string]User ID"
metadata: "[string]Metadata corresponding to the content of the message"
readAcquireActions:
- action: "[string]Types of actions to be performed in the acquire action"
request: "[string]JSON string of the request used when executing the action"
expiresAt: "[long]Datetime of ttl"
expiresTimeSpan:
days: "[int]Number of days from the reference time"
hours: "[int]Hours from the reference time"
minutes: "[int]Minutes from the reference time"
timeOffsetToken: "[string]Time offset token"transaction.service("inbox").acquire.send_message_by_user_id({
namespaceName="[string]Namespace name",
userId="[string]User ID",
metadata="[string]Metadata corresponding to the content of the message",
readAcquireActions={
{
action="[string]Types of actions to be performed in the acquire action",
request="[string]JSON string of the request used when executing the action"
}
},
expiresAt="[long]Datetime of ttl",
expiresTimeSpan={
days="[int]Number of days from the reference time",
hours="[int]Hours from the reference time",
minutes="[int]Minutes from the reference time"
},
timeOffsetToken="[string]Time offset token",
})