Home docs switch Online Play Invitations
Post

Online Play Invitations

URL: https://app.lp1.five.nintendo.net

This server manages online play invitations.

Log in on BaaS in order to obtain an access token for this service.

This server takes JSON-encoded requests and responds with JSON-encoding.

Methods

MethodURL
GET/v1/users/<id>/invitations/inbox
GET/v2/users/<id>/invitations/inbox
GET/v1/invitation_groups/<id>
POST/v1/invitation_groups
POST/v2/invitation_groups
PATCH/v1/invitations
PATCH/v1/users/<id>/invitations/mark_as_read

GET /<version>/users/<id>/invitations/inbox

This method returns incoming invitations. The version is v1 up to system version 19.0.1 and v2 in system version 20.0.0 and later.

This method takes the following query parmeters:

ParamDescription
fieldsComma-separated list of fields that should be returned by the server
readSpecifies whether the server should return only unread invitation (false) or all invitations (true)
invitation_typesHardcoded to friend (only present in v2)

All parameters are optional. The friends sysmodule currently either sends fields=count&read=false, or does not send these parameters at all.

Response on success:

FieldDescription
countTotal number of invitations
itemsInvitation list

An invitation has the following fields:

FieldDescription
idInvitation id generated by server (integer)
invitation_group_idInvitation group id generated by server (integer)
sender_idUser id of sender (16 hex digits)
application_idTitle id from which the invitation was sent (16 hex digits)
application_group_idPresence group id for the current title (usually the same as the title id)
application_id_matchUnknown (always false)
application_dataGame-specific information (base64)
readWhether the invitation is marked as read (boolean)
created_atCreation timestamp
updated_atUpdate timestamp

GET /v1/invitation_groups/<id>

This method returns a specific invitation group.

POST /<version>/invitation_groups

This method sends an invitation to other users. The version is v1 up to system version 19.0.1 and v2 in system version 20.0.0 and later.

This method takes the following parameters:

FieldDescription
receiver_idsList of baas account ids
invitation_typeHardcoded to friend (only present in v2)
application_idTitle id from which the invitation was sent
acd_indexUnknown (added in system version 19.0.0)
application_group_idPresence group id for the current title (usually the title id)
application_dataOptional game-specific information (base64 encoded)
messagesDictionary containing a message per language. The following languages may be used: en-US, en-GB, ja, fr, de, es-419, es, it, nl, fr-CA, pt, ru, zh-Hans, zh-Hant, ko, pt-BR
application_id_matchUnknown (always false)

Returns an invitation group on success.

Invitation Group

FieldDescription
idInvitation group id
sender_idBaas user id of the sender
invitation_typeThe invitation type
application_idTitle id
application_group_idPresence group id
application_id_matchUnknown
acd_indexUnknown
application_dataGame-specific information
messagesMessages
created_atTimestamp
updated_atTimestamp
invitationsList of invitations

Every invitation has the following fields:

FieldDescription
idInvitation id
receiver_idBaas user id of receiver

Errors

On error, the server sends the following response:

FieldDescription
errorError information

The error information is encoded like this:

FieldDescription
codeError code (string with 4 digits)
messageError message

Known Errors

CodeStatusMessage
0001500Internal server error.
0002400Invalid parameter.
0003404Invalid request URI.
0004??
0005??
0006401Unauthorized.
0007??
0008??
0009??
0010404Resource not found.
0011400Application data is too large.
Contents