Module name | datastore |
API version | 2 |
The following values must be encoded in Base64 in the request. The response will also use Base64 encoding.
Gets the metadata of data.
Gets the metadata for one piece of data, data_id.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to get the metadata for.Required |
response | Additional information to retrieve. For more information, see the table below. You can specify multiple values, delimited by commas. |
Request Examples:
Get metadata for data ID 10
.
GET /nex/datastore/v2/metainfo/10 HTTP/1.1
Gets the metadata of multiple pieces of data.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to get the metadata for. You can specify up to 100, delimited by commas.Required |
response | Additional information to retrieve. For more information, see the table below. You can specify multiple values, delimited by commas. |
Request Examples:
Get metadata for data IDs 10
, 20
, and 30
.
GET /nex/datastore/v2/metainfo?data_ids=10,20,30 HTTP/1.1
response
Value | Details |
---|---|
meta_ |
Meta-binary data |
tags | Tags |
ratings | Ratings |
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<metainfos length="1">
<metainfo>
<data_id>10</data_id>
<name>name</name>
<owner_id>100</owner_id>
<size>100</size>
<type>100</type>
<access_permission>
<type>public</type>
<recipient_ids length="0"/>
</access_permission>
<update_permission>
<type>private</type>
<recipient_ids length="0"/>
</update_permission>
<flags length="0"/>
<period>30</period>
<created_time>2013-01-01T00:00:00Z</created_time>
<updated_time>2013-01-01T00:00:00Z</updated_time>
<referred_time>2013-01-01T00:00:00Z</referred_time>
<expire_time>2013-01-30T00:00:00Z</expire_time>
<status>none</status>
<referred_count>0</referred_count>
<refer_data_id>0</refer_data_id>
<tags length="2">
<tag>dGFnMQ==</tag>
<tag>dGFnMg==</tag>
</tags>
<meta_binary></meta_binary>
<ratings length="1">
<rating>
<slot>0</slot>
<count>1</count>
<total_value>100</total_value>
<initial_value>0</initial_value>
</rating>
</ratings>
</metainfo>
</metainfos>
</datastore>
</nex>
meta_binary
and tag
are in URL-safe Base64 encoded format.
Changes the metadata of data.
Although generally only the specified information is changed, the expiration is also updated if the number of days valid or date modified is changed.
Changes the metadata for one piece of data, data_id.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to change.Required |
Request body:
Element | New Elements | Details |
---|---|---|
change | Root element.Required | |
name | change | Name. |
period | change | The number of valid days. |
status | change | The status. For more information, see the table below. |
referred_ |
change | Specifies the number of references. |
access_ |
change | Access permission. Configured in the child element. |
update_ |
change | Update permissions. Configured in the child element. |
type | access_ |
Permission type. For more information, see the table below. |
recipient_ |
access_ |
User with permission. If type is specified or specified_ |
recipient_ |
recipient_ |
User with permission. Multiple users can be specified. |
tags | change | Tags. Specify in the tag child element. |
tag | tags | Tags. Specify the value as a URL-safe Base64-encoded string. Multiple values can be specified (up to 16). |
meta_ |
change | Meta-binary data. Specify the value as a URL-safe Base64-encoded string. |
modify_ |
change | To update the modified date to the current date, specify 1. |
Request Examples:
Change the metadata for data ID 10
as follows.
PUT /nex/datastore/v2/metainfo/10 HTTP/1.1
<change>
<name>new name</name>
<access_permission>
<type>public</type>
</access_permission>
<tags>
<tag>dGFn</tag>
</tags>
</change>
Changes the metadata of multiple pieces of data.
Request body:
Element | New Elements | Details |
---|---|---|
change | Root element.Required | |
name | change | Name. |
period | change | The number of valid days. |
status | change | The status. For more information, see the table below. |
referred_ |
change | Specifies the number of references. |
access_ |
change | Access permission. Configured in the child element. |
update_ |
change | Update permissions. Configured in the child element. |
type | access_ |
Permission type. For more information, see the table below. |
recipient_ |
access_ |
User with permission. If type is specified or specified_ |
recipient_ |
recipient_ |
User with permission. Multiple users can be specified. |
tags | change | Tags. Specify in the tag child element. |
tag | tags | Tags. Specify the value as a URL-safe Base64 -encoded string. Multiple values can be specified (up to 16). |
meta_ |
change | Meta-binary data. Specify the value as a URL-safe Base64-encoded string. |
modify_ |
change | To update the modified date to the current date, specify 1. |
param | change | The data to change. Multiple values can be specified (up to 100).Required |
data_ |
param | The data ID to change.Required |
Request Examples:
Change the metadata for data IDs 10
and 20
as follows.
100
only.PUT /nex/datastore/v2/metainfo HTTP/1.1
<change>
<name>new name</name>
<update_permission>
<type>specified</type>
<recipient_ids>
<recipient_id>100</recipient_id>
</recipient_ids>
</update_permission>
<param>
<data_id>10</data_id>
</param>
<param>
<data_id>20</data_id>
</param>
</change>
status
Value | Details |
---|---|
none | Normal state. |
pending | Rating Pending |
rejected | Rejected. |
access_permission/type, update_permission/type
Value | Details |
---|---|
public | Overall. |
friend | Friends only. |
specified | Only the specified recipient(s). Must be specified in the recipient_ |
private | Oneself only. |
specified_ |
Only the specified friend(s). Must be specified in the recipient_ |
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<metainfo>
<changed length="2" />
</metainfo>
</datastore>
</nex>
Deletes data.
Deletes one piece of data, data_id.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to delete.Required |
Request Examples:
Delete the data with a data ID of 10
.
DELETE /nex/datastore/v2/data/10 HTTP/1.1
Deletes multiple pieces of data.
Request body:
Element | New Elements | Details |
---|---|---|
delete | Root element.Required | |
param | delete | The data to delete. Multiple values can be specified (up to 100).Required |
data_ |
param | The data ID to delete.Required |
Request Examples:
Delete the data with a data IDs of 10
and 20
.
POST /nex/datastore/v2/data/delete HTTP/1.1
<delete>
<param>
<data_id>10</data_id>
</param>
<param>
<data_id>20</data_id>
</param>
</delete>
HTTP/1.1 200 OK Content-Type: text/xml;charset=utf-8 <?xml version="1.0" encoding="UTF-8"?> <nex> <datastore> <data> <deleted length="2" /> </data> </datastore> </nex>
Searches data.
Parameters:
Name | Details |
---|---|
type | Data type. |
owner_ |
Owner ID. You can specify multiple values, delimited by commas. |
owner_ |
Owner type. For more information, see the table below. |
name | Name. Specify a URL-encoded value. |
tags | Tags. Specify the value as a URL-safe Base64-encoded string. If you have more than one tag, encode each tag, and delimit them with commas. |
created_ |
Start of creation date range (UNIX timestamp). |
created_ |
End of creation date range (UNIX timestamp). |
updated_ |
Start of update date range (UNIX timestamp). |
updated_ |
End of update date range (UNIX timestamp). |
sort | Sort order. For more information, see the table below. |
offset | Position to start getting results. If you specify any, a pseudo-random order is used based on sort. |
limit | The number of results to get. The maximum value is 10000. However, the maximum is only 20 if offset is set to any. |
response | Additional data to include in the response. For more information, see the table below. You can specify multiple values, delimited by commas. |
Request Examples:
Search for data with a data type of 100
.
GET /nex/datastore/v2/metainfo/search?type=100 HTTP/1.1
owner_type
Value | Details |
---|---|
anybody | Everyone. |
exclude_ |
An ID other than those specified in owner_ |
sort
The default sort order is ascending. Prefix the name with a hyphen ("-") to sort in descending order.
Name | Comments |
---|---|
data_ id |
Data ID |
size | Data size |
name | Name |
type | Data type |
created_ time |
Creation date and time |
updated_ time |
Date modified |
owner_ id |
Owner ID. |
response
Value | Details |
---|---|
meta_ |
Meta-binary data |
tags | Tags |
ratings | Ratings |
url | URL for the data, which expires after 30 days. |
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<metainfos length="1" offset="0" total="100" total_type="exact">
<metainfo>
<data_id>10</data_id>
<name>name</name>
<owner_id>100</owner_id>
<size>100</size>
<type>100</type>
<access_permission>
<type>public</type>
<recipient_ids length="0"/>
</access_permission>
<update_permission>
<type>private</type>
<recipient_ids length="0"/>
</update_permission>
<flags length="0"/>
<period>30</period>
<created_time>2013-01-01T00:00:00Z</created_time>
<updated_time>2013-01-01T00:00:00Z</updated_time>
<referred_time>2013-01-01T00:00:00Z</referred_time>
<expire_time>2013-01-30T00:00:00Z</expire_time>
<status>none</status>
<referred_count>0</referred_count>
<refer_data_id>0</refer_data_id>
</metainfo>
</metainfos>
</datastore>
</nex>
meta_binary
and tag
are in URL-safe Base64 encoded format.
prepare
. Set size to the size of the data to upload (in bytes). Specify other parameters as necessary.complete
and include the data ID returned from prepare
in the path.prepare
. The size parameter is 0. Set flag to not_use_storageserver and meta_binary to the data to upload, as a URL-safe Base64-encoded string.complete
.Prepares to upload data.
Request body:
Element | New Elements | Details |
---|---|---|
prepare | Root element.Required | |
size | prepare | Size of the data to be uploaded.Required |
owner_ id |
prepare | The principal ID to set as the data owner. |
type | prepare | Data type. The default is 0. |
meta_ |
prepare | Meta-binary data. Specify the value as a URL-safe Base64-encoded string. |
flags | prepare | Flag. Specify in the flag child element. |
flag | flags | Flag. For more information, see the table below. Multiple users can be specified. |
period | prepare | The number of valid days. The default is 90. |
refer_ |
prepare | Data ID to associate. |
access_ |
prepare | Access permission. |
update_ |
prepare | Update permissions. |
type | access_ |
Permission type. For more information, see the table below. |
recipient_ |
access_ |
User with permission. If type is specified or specified_ |
recipient_ |
recipient_ |
User with permission. Multiple users can be specified. |
tags | prepare | Tags. Specify in the tag child element. |
tag | tags | Tags. Specify the value as a URL-safe Base64-encoded string. Multiple values can be specified (up to 16). |
rating_ |
prepare | Rating initialization parameters. Specify in child elements. |
param | rating_ |
An individual rating initialization parameter. Multiple values can be specified (up to 16). |
slot | param | Rating slot. |
flags | param | Rating option flags. Specify in the flag child element. |
flag | flags | Rating option flags. For more information, see the table below. Multiple users can be specified. |
initial_ |
param | Initial value for ratings. |
range_ |
param | Minimum rating value. |
range_ |
param | Maximum rating value. |
lock | param | Duplicate lock. Specify in child elements. |
type | lock | Lock type. For more information, see the table below. |
period_ |
lock | Time at which to remove the lock. Only valid when type is period. |
period_ |
lock | The lock period. Duration in seconds when type is internal and in days when it is period. |
persistence_ |
prepare | Persistence parameter. Specify in child elements. |
slot | persistence_ |
Slot to use for persistence. |
delete_ |
persistence_ |
Specify whether to delete previous data. Set it to 1 (true ) or 0 (false ). |
If owner_id
is not specified, then the user with the second principal ID is used as the official user.
Request Examples:
Prepare 100 bytes of data for upload.
POST /nex/datastore/v2/data/prepare HTTP/1.1
<prepare>
<size>100</size>
</prepare>
flags/flag
Value | Details |
---|---|
none | Not set. |
need_ |
Indicates that a data review is required by an administrator. |
period_ |
Determines the expiration date and time using the time elapsed since the last access. |
use_ |
Notifies to recipient when data is uploaded. |
not_ |
Storage server is not used with only meta-binary data. |
access_permission/type, update_permission/type
Value | Details |
---|---|
public | Overall. |
friend | Friends only. |
specified | Only the specified recipient(s). |
private | Oneself only. |
specified_ |
Specified users who are friends. |
rating_init_params/param/flags/flag
Value | Details |
---|---|
modifiable | Enables modification. |
round_ |
Rounded to 0 for negative results from subtraction. |
disable_ |
Disables self-rating. |
rating_init_params/param/lock/type
Value | Details |
---|---|
none | Duplicate locks are not used. |
interval | Lock by interval. |
period | Lock by expiration date. |
permanent | Permanent lock. |
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<data>
<url>dev.example.org/</url>
<request_header>
<date>Wed, 01 Jan 2013 00:00:00 GMT</date>
</request_header>
<post_param>
<policy>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</policy>
<AWSAccessKeyId>XXXXXXXXXXXXXXXXXXXX</AWSAccessKeyId>
<signature>XXXXXXXXXXXXXXXXXXXX</signature>
<key>XXXXXXXXXXXXXXXXXXXX</key>
<acl>private</acl>
</post_param>
<data_id>10</data_id>
</data>
</datastore>
</nex>
Element | New Elements | Details |
---|---|---|
data |
Root element. | |
data_ id |
data |
Data ID. Specify on complete . When only uploading a meta binary, set only this value. |
url | data |
Specifies the request URL for the storage server. Use https:// for the request. |
request_ |
data |
Request header for storage server. |
date | request_ |
Date. |
post_ |
data |
Request parameter for storage server. |
policy | post_ |
Policy. |
AWSAccessKeyId | post_ |
Access key. |
signature | post_ |
Signature. |
key | post_ |
Key indicating the location of the data. |
acl | post_ |
Access control. |
Completes the data upload.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to complete.Required |
Request body:
Element | New Elements | Details |
---|---|---|
complete | Root element. | |
owner_ id |
complete | The principal ID to set as the data owner. |
If owner_id
is not specified, then the user with the second principal ID is used as the official user.
Request Examples:
Use prepare
to complete the upload of the data for which a data ID of 10
was returned.
POST /nex/datastore/v2/data/complete/10 HTTP/1.1
HTTP/1.1 200 OK
Gets the URL for a single piece of data, data_id.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to get the URL for.Required |
period | The number of days that the URL is valid. The default is 30. |
Request Examples:
Get the URL for data ID 10
.
GET /nex/datastore/v2/urlinfo/10 HTTP/1.1
Gets the URL of multiple pieces of data.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to get the URL for. You can specify up to 100, delimited by commas.Required |
period | The number of days that the URL is valid. The default is 30. |
Request Examples:
Get the URLs for data IDs 10
, 20
, and 30
.
GET /nex/datastore/v2/urlinfo?data_ids=10,20,30 HTTP/1.1
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<urlinfos length="1">
<urlinfo>
<data_id>10</data_id>
<url>dev.example.org</url>
</urlinfo>
</urlinfos>
</datastore>
</nex>
Gets the password for a single piece of data, data_id.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to get the password for.Required |
Request Examples:
Get the password for data ID 10
.
GET /nex/datastore/v2/passwordinfo/10 HTTP/1.1
Gets the passwords of multiple pieces of data.
Parameters:
Name | Details |
---|---|
data_ |
The data ID to get the password for. You can specify up to 100, delimited by commas.Required |
Request Examples:
Get the passwords for data IDs 10
, 20
, and 30
.
GET /nex/datastore/v2/passwordinfo?data_ids=10,20,30 HTTP/1.1
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<passwordinfos length="1">
<passwordinfo>
<access_password>XXXXXXXXXXXXXXXXXXXX</access_password>
<update_password>XXXXXXXXXXXXXXXXXXXX</update_password>
<data_id>10</data_id>
</passwordinfo>
</passwordinfos>
</datastore>
</nex>
Rates data.
Rates a single piece of data (data_id) using the rating slot (slot).
Parameters:
Name | Details |
---|---|
data_ |
The data ID to rate.Required |
slot | The rating slot to use.Required |
Request body:
Element | New Elements | Details |
---|---|---|
rate | Root element.Required | |
rating_ |
rate | Rating value.Required |
Request Examples:
Using rating slot 0
, rate data ID 10
as 100
.
PUT /nex/datastore/v2/metainfo/10/ratings/0 HTTP/1.1
<rate>
<rating_value>100</rating_value>
</rate>
Rate multiple pieces of data in multiple rating slots.
Request body:
Element | New Elements | Details |
---|---|---|
rate | Root element.Required | |
param | rate | Data to rate and slots to use. Multiple values can be specified (up to 100).Required |
data_ |
param | The data ID to rate.Required |
slot | param | The rating slot to use.Required |
rating_ |
param | Rating value.Required |
Request Examples:
Rate data as follows.
10
as 100
using rating slot 0
.20
as 200
using rating slot 0
.20
as 210
using rating slot 1
.PUT /nex/datastore/v2/metainfo/ratings HTTP/1.1
<rate>
<param>
<data_id>10</data_id>
<slot>0</slot>
<rating_value>100</rating_value>
</param>
<param>
<data_id>20</data_id>
<slot>0</slot>
<rating_value>200</rating_value>
</param>
<param>
<data_id>20</data_id>
<slot>1</slot>
<rating_value>210</rating_value>
</param>
</rate>
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<metainfo>
<ratings>
<rating>
<count>1</count>
<initial_value>0</initial_value>
<total_value>100</total_value>
</rating>
</ratings>
</metainfo>
</datastore>
</nex>
Resets the ratings for a single piece of data (data_id).
Parameters:
Name | Details |
---|---|
data_ |
The data ID to reset the rating for.Required |
Request Examples:
Reset the rating of data ID 10
.
DELETE /nex/datastore/v2/metainfo/10/ratings HTTP/1.1
Resets the ratings of multiple pieces of data.
Request body:
Element | New Elements | Details |
---|---|---|
reset | Root element.Required | |
param | reset | The data to reset the ratings for. Multiple values can be specified (up to 100).Required |
data_ |
param | The data ID to reset the rating for.Required |
Request Examples:
Reset the ratings of data IDs 10
and 20
.
POST /nex/datastore/v2/metainfo/ratings/delete HTTP/1.1
<reset>
<param>
<data_id>10</data_id>
</param>
<param>
<data_id>20</data_id>
</param>
</reset>
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<metainfo>
<ratings>
<reset length="2" />
</ratings>
</metainfo>
</datastore>
</nex>
Gets the data persistence information.
Gets the persistence information from the persistence slot (slot) of principal_id.
Parameters:
Name | Details |
---|---|
principal_ |
Specifies the principal ID with the persistence information to get.Required |
slot | Specifies the persistence slot to get.Required |
Request Examples:
Get the information in persistence slot 0
for data ID 10
.
GET /nex/datastore/v2/persistenceinfo/10/0 HTTP/1.1
Gets the persistence information for multiple pieces of data.
Parameters:
Name | Details |
---|---|
principal_ |
Specifies the principal ID with the persistence information to get.Required |
slots | Specifies the persistence slot to get. You can specify up to 16, delimited by commas.Required |
Request Examples:
Get the information in persistence slots 0
, 1
, and 2
for data ID 10
.
GET /nex/datastore/v2/persistenceinfo?principal_id=10&slots=0,1,2 HTTP/1.1
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<persistenceinfos length="1">
<persistenceinfo>
<principal_id>100</principal_id>
<data_id>10</data_id>
<slot>0</slot>
</persistenceinfo>
</persistenceinfos>
</datastore>
</nex>
Makes data persistent.
Makes data persistent using the persistence slot slot of principal_id.
Parameters:
Name | Details |
---|---|
principal_ |
Specifies the principal ID to persist.Required |
slots | Slot to use for persistence.Required |
Request body:
Element | New Elements | Details |
---|---|---|
perpetuate | Root element.Required | |
data_ |
perpetuate | The data ID of the data that is perpetuated.Required |
delete_ |
perpetuate | Specify whether to delete previous data. Set it to 1 (true ) or 0 (false ). The default is 1. |
Request Examples:
Persists the data with a data ID of 10
using persistence slot 0
of principal ID 100
.
PUT /nex/datastore/v2/persistenceinfo/100/0 HTTP/1.1
<perpetuate>
<data_id>10</data_id>
</perpetuate>
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<persistenceinfo>
<perpetuated length="1" />
</persistenceinfo>
</datastore>
</nex>
Makes persistent data non-persistent.
Unpersists the persistent data in the persistence slot slot of principal_id.
Parameters:
Name | Details |
---|---|
principal_ |
Specifies the principal ID to unpersist. Required |
slots | Slot to use for unpersistence. Required |
Request body:
This can only be used with the POST method.
Element | New Elements | Details |
---|---|---|
unperpetuate | Root element. | |
delete_ |
unperpetuate | Specify whether to delete the unpersisted data. Set it to 1 (true ) or 0 (false ). The default is 0. |
Request Examples:
Unpersist the persistent data in persistence slot 0
of principal ID 100
.
DELETE /nex/datastore/v2/persistenceinfo/100/0 HTTP/1.1
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<persistenceinfo>
<unperpetuated length="1" />
</persistenceinfo>
</datastore>
</nex>
The version is not specified in this API function.
Gets the version.
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
<?xml version="1.0" encoding="UTF-8"?>
<nex>
<datastore>
<api_version>2</api_version>
<ngs_version>3.6.2.</ngs_version>
</datastore>
</nex>
ngs_version
The string showing the NGS version uses the format (MAJOR VERSION).(MINOR VERSION).(MICRO VERSION).(PATCH VERSION)
. The patch version is usually blank. Special versions for specific titles add a game code.
CONFIDENTIAL