*เนื้อหานี้แปลโดยใช้ AI (เวอร์ชัน Beta) และอาจมีข้อผิดพลาด หากต้องการดูหน้านี้เป็นภาษาอังกฤษ ให้คลิกที่นี่

OrderedDataStoreEntry

รายการคีย์-ค่าในคลังข้อมูลที่สั่งซื้อ

คุณลักษณะ

pathstring

เส้นทางทรัพยากรของรายการคลังข้อมูลที่สั่งซื้อ

รูปแบบ: universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{ordered_data_store_scope_id}/entries/{ordered_data_store_entry_id}.

valuenumber

มูลค่าของรายการ

ตัดตัวเลขที่ใกล้เคียงที่สุดเสมอ.

idstring
เอาต์พุตเท่านั้น

ชื่อของรายการ.

URL หลัก

https://apis.roblox.com
แหล่งข้อมูล OrderedDataStoreEntry

{
"path": "universes/123/ordered-data-stores/some-ordered-data-store-id/scopes/some-ordered-data-store-scope-id/entries/some-ordered-data-store-entry-id",
"value": "number",
"id": "string"
}

OrderedDataStoreEntry

รายการเก็บข้อมูลที่จัดเรียงตามลําดับ
เวอร์ชัน Beta

GET /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries

คืนรายการของรายการจากคลังข้อมูลที่สั่งซื้อ

ขอบเขต
universe.ordered-data-store.scope.entry:read
คำขอพารามิเตอร์เส้นทาง
universe_idstring
จำเป็นต้องมี

ID ของจักรวาล.

ordered_data_store_idstring
จำเป็นต้องมี

รหัสร้านข้อมูลที่สั่งซื้อ.

scope_idstring
จำเป็นต้องมี

รหัสขอบเขต.

พารามิเตอร์คิวรี
maxPageSizenumber

จํานวนสูงสุดของบันทึกคลังข้อมูลที่สั่งซื้อที่จะส่งคืนบริการอาจ返回值น้อยกว่านี้หากไม่ระบุ จะมีการคืนสถานที่เก็บข้อมูลที่สั่งซื้อสูงสุด 10 รายการมูลค่าสูงสุดคือ 100 และมูลค่าที่สูงกว่าจะถูกตั้งเป็น 100.

pageTokenstring

โทเค็นหน้าที่ได้รับจากการโทรก่อนหน้านี้เพื่อดึงหน้าต่อไป

เมื่อจัดหน้า พารามิเตอร์อื่น ๆ ทั้งหมดที่ให้กับการโทรต่อไปจะต้องตรงกับการโทรที่ให้โทเค็นหน้า.

orderBystring

หากระบุไว้ ผลลัพธ์จะถูกจัดเรียงตามช่องที่ระบุ

ค่าต้องเป็นรายการแยกกับจุลภาคของฟิลด์ที่มี "desc" เป็นส่วนท้ายที่เลือกได้เพื่อเรียงลําดับตามลําดับลงแทนที่จะเรียงลําดับตามมูลค่าเพิ่มขึ้นคุณสามารถเข้าถึงสนามย่อยด้วยตัวประกอบ .

ผลลัพธ์สามารถจัดเรียงตามฟิลด์ต่อไปนี้: ค่า

ตัวอย่าง: "value desc".

filterstring

ฟิลด์นี้อาจถูกตั้งค่าเพื่อกรองทรัพยากรที่ส่งคืน

เราสนับสนุนผู้ประกอบเปรียบเทียบสองรายการสำหรับการดำเนินการนี้: <= และ >= ผู้ประกอบเปรียบเทียบเหล่านี้ทำหน้าที่เป็นมูลค่าน้อยสุดและมูลค่าสูงสุดสำหรับค่าที่ส่งคืนหากต้องการการกรองสำหรับค่าระหว่าง minValue และ maxValue ผู้ใช้สามารถใช้ตัวประกอบทางการตรรกะ &&โทเค็นทั้งหมดในสูตรการกรองต้องแยกกับพื้นที่เดียว

ตัวกรองตัวอย่าง: entry <= 10 ; entry >= 10 && entry <= 30.

การตอบกลับ

รายการของ OrderedDataStoreEntries ในคอลเลกชันราก

orderedDataStoreEntriesarray<OrderedDataStoreEntry>

ส่วนประกอบข้อมูลที่สั่งซื้อจากสถานที่เก็บข้อมูลที่สั่งซื้อที่ระบุ.

nextPageTokenstring

โทเคนที่คุณสามารถส่งเป็นพารามิเตอร์ pageToken เพื่อดึงหน้าถัดไป หากฟิลด์นี้ถูกข้ามไป จะไม่มีหน้าต่อไป.

GET /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries

curl -L -X GET 'https://apis.roblox.com/cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries?maxPageSize=10&pageToken={string}&orderBy={string}&filter={string}' \
-H 'x-api-key: {your-api-key}'
การตอบกลับ

{
"orderedDataStoreEntries": [
{
"path": "universes/123/ordered-data-stores/some-ordered-data-store-id/scopes/some-ordered-data-store-scope-id/entries/some-ordered-data-store-entry-id",
"value": "number",
"id": "string"
}
],
"nextPageToken": "string"
}

OrderedDataStoreEntry

สร้างบันทึกที่จัดเรียงข้อมูลร้านค้าเข้า
เวอร์ชัน Beta

POST /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries

สร้างบันทึกด้วยรหัสและค่าที่ให้ไว้

ส่งคืนคำขอไม่ดี 400 ถ้ามีการบันทึก

ขอบเขต
universe.ordered-data-store.scope.entry:write
คำขอพารามิเตอร์เส้นทาง
universe_idstring
จำเป็นต้องมี

ID ของจักรวาล.

ordered_data_store_idstring
จำเป็นต้องมี

รหัสร้านข้อมูลที่สั่งซื้อ.

scope_idstring
จำเป็นต้องมี

รหัสขอบเขต.

พารามิเตอร์คิวรี
idstring

ID ที่จะใช้สำหรับการจัดเก็บข้อมูลที่สั่งซื้อซึ่งจะกลายเป็นส่วนสุดท้ายของเส้นทางทรัพยากรของคลังข้อมูลที่สั่งซื้อ

ค่านี้ควรเป็นสตริงตัวอักษร 1-63 ตัว เราขอแนะนำให้ใช้เฉพาะตัวอักษรภาษาต่ำเท่านั้น ตัวเลข และเครื่องหมายแยกกับเท่านั้น.

เนื้อหาคำขอOrderedDataStoreEntry
การตอบกลับOrderedDataStoreEntry
POST /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries

curl -L -X POST 'https://apis.roblox.com/cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries?id=my-entry' \
-H 'x-api-key: {your-api-key}' \
-H 'Content-Type: application/json' \
--data '{
"value": "number"
}'
การตอบกลับ

{
"path": "universes/123/ordered-data-stores/some-ordered-data-store-id/scopes/some-ordered-data-store-scope-id/entries/some-ordered-data-store-entry-id",
"value": "number",
"id": "string"
}

OrderedDataStoreEntry

รับการจัดเก็บข้อมูลร้านค้าสั่งซื้อ
เวอร์ชัน Beta

GET /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}

รับรายการที่กำหนดไว้

ขอบเขต
universe.ordered-data-store.scope.entry:read
คำขอพารามิเตอร์เส้นทาง
universe_idstring
จำเป็นต้องมี

ID ของจักรวาล.

ordered_data_store_idstring
จำเป็นต้องมี

รหัสร้านข้อมูลที่สั่งซื้อ.

scope_idstring
จำเป็นต้องมี

รหัสขอบเขต.

entry_idstring
จำเป็นต้องมี

ID ของรายการ.

การตอบกลับOrderedDataStoreEntry
GET /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}

curl -L -X GET 'https://apis.roblox.com/cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}' \
-H 'x-api-key: {your-api-key}'
การตอบกลับ

{
"path": "universes/123/ordered-data-stores/some-ordered-data-store-id/scopes/some-ordered-data-store-scope-id/entries/some-ordered-data-store-entry-id",
"value": "number",
"id": "string"
}

OrderedDataStoreEntry

ลบบันทึกที่จัดเรียงข้อมูลของร้านข้อมูลที่สั่งไว้
เวอร์ชัน Beta

DELETE /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}

ลบรายการที่ระบุ

เมื่อสำเร็จจะ返回 200 OK หากรายการไม่มีอยู่จะ返回 404 ไม่พบ

ขอบเขต
universe.ordered-data-store.scope.entry:write
คำขอพารามิเตอร์เส้นทาง
universe_idstring
จำเป็นต้องมี

ID ของจักรวาล.

ordered_data_store_idstring
จำเป็นต้องมี

รหัสร้านข้อมูลที่สั่งซื้อ.

scope_idstring
จำเป็นต้องมี

รหัสขอบเขต.

entry_idstring
จำเป็นต้องมี

ID ของรายการ.

DELETE /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}

curl -L -X DELETE 'https://apis.roblox.com/cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}' \
-H 'x-api-key: {your-api-key}'

OrderedDataStoreEntry

อัปเดตรายการเก็บข้อมูลที่สั่งซื้อ
เวอร์ชัน Beta

PATCH /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}

อัปเดตมูลค่าของรายการ

ขอบเขต
universe.ordered-data-store.scope.entry:write
คำขอพารามิเตอร์เส้นทาง
universe_idstring
จำเป็นต้องมี

ID ของจักรวาล.

ordered_data_store_idstring
จำเป็นต้องมี

รหัสร้านข้อมูลที่สั่งซื้อ.

scope_idstring
จำเป็นต้องมี

รหัสขอบเขต.

entry_idstring
จำเป็นต้องมี

ID ของรายการ.

พารามิเตอร์คิวรี
allowMissingboolean

หากตั้งค่าเป็นจริงและไม่พบรายการคลังข้อมูลที่สั่งซื้อ จะสร้างรายการคลังข้อมูลที่สั่งซื้อ.

เนื้อหาคำขอOrderedDataStoreEntry
การตอบกลับOrderedDataStoreEntry
PATCH /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}

curl -L -X PATCH 'https://apis.roblox.com/cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}?allowMissing={boolean}' \
-H 'x-api-key: {your-api-key}' \
-H 'Content-Type: application/json' \
--data '{
"value": "number"
}'
การตอบกลับ

{
"path": "universes/123/ordered-data-stores/some-ordered-data-store-id/scopes/some-ordered-data-store-scope-id/entries/some-ordered-data-store-entry-id",
"value": "number",
"id": "string"
}

OrderedDataStoreEntry

บันทึกการเพิ่มลำดับข้อมูลที่จัดเก็บอยู่
เวอร์ชัน Beta

POST /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}:increment

เพิ่มมูลค่าของรายการที่ระบุ ทั้งมูลค่าที่มีอยู่และจำนวนการเพิ่มต้องเป็นตัวเลข

หากรายการไม่มีอยู่ จะสร้างรายการด้วยค่าที่ระบุ

ปัญหาที่รู้จัก: ค่าอาจเพิ่มขึ้นเกินขอบเขตที่ถูกต้องของค่าเมื่อเกิดเหตุนี้ขึ้น ค่าที่ส่งกลับจะถูกจำกัดไว้ที่ช่วงที่ถูกต้อง แต่เบ็คอันด์อาจยังคงเก็บค่าเดิมไว้พฤติกรรมนี้จะถูกรักษาไว้เพื่อเหตุผลของการสอดคล้องกับรุ่นก่อนหน้า แต่อาจเปลี่ยนแปลงในรุ่นต่อไปของ API นี้

ขอบเขต
universe.ordered-data-store.scope.entry:write
คำขอพารามิเตอร์เส้นทาง
universe_idstring
จำเป็นต้องมี

ID ของจักรวาล.

ordered_data_store_idstring
จำเป็นต้องมี

รหัสร้านข้อมูลที่สั่งซื้อ.

scope_idstring
จำเป็นต้องมี

รหัสขอบเขต.

entry_idstring
จำเป็นต้องมี

ID ของรายการ.

เนื้อหาคำขอ
amountnumber

จำนวนที่จะเพิ่มมูลค่าเข้าสู่ตัวเลข ทั้งมูลค่าที่มีอยู่และจำนวนการเพิ่มต้องเป็นตัวเลข.

การตอบกลับOrderedDataStoreEntry
POST /cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}:increment

curl -L -X POST 'https://apis.roblox.com/cloud/v2/universes/{universe_id}/ordered-data-stores/{ordered_data_store_id}/scopes/{scope_id}/entries/{entry_id}:increment' \
-H 'x-api-key: {your-api-key}' \
-H 'Content-Type: application/json' \
--data '{
"amount": "number"
}'
การตอบกลับ

{
"path": "universes/123/ordered-data-stores/some-ordered-data-store-id/scopes/some-ordered-data-store-scope-id/entries/some-ordered-data-store-entry-id",
"value": "number",
"id": "string"
}