Shop
These API endpoints are related to the Omniplex shop.
GET
Gets the publicly viewable shop coupons on the list
Success
application/json- response
items?array<>curl -X GET 'https://spider.omniplex.gg/shop/public-coupons'Example Response
{ "items": [ { "allowed_users": [ "string" ], "applicable_items": [ "string" ], "cents": 0.1, "code": "string", "created_at": "2019-08-24T14:15:22Z", "created_by": { "avatar": "string", "bot": true, "display_name": "string", "extra_data": { "property1": null, "property2": null }, "flags": [ "string" ], "id": "string", "status": "string", "username": "string" }, "expiry": 0, "id": "string", "last_updated": "2019-08-24T14:15:22Z", "max_uses": 0, "public": true, "requirements": [ "string" ], "reuse_wait_duration": 0, "target_types": [ "string" ], "updated_by": { "avatar": "string", "bot": true, "display_name": "string", "extra_data": { "property1": null, "property2": null }, "flags": [ "string" ], "id": "string", "status": "string", "username": "string" }, "usable": true } ]}GET
Gets the publicly viewable shop items on the list
Success
application/json- response
items?array<>curl -X GET 'https://spider.omniplex.gg/shop/items'Example Response
{ "items": [ { "benefits": [ "string" ], "cents": 0.1, "created_at": "2019-08-24T14:15:22Z", "created_by": { "avatar": "string", "bot": true, "display_name": "string", "extra_data": { "property1": null, "property2": null }, "flags": [ "string" ], "id": "string", "status": "string", "username": "string" }, "description": "string", "duration": 0, "id": "string", "last_updated": "2019-08-24T14:15:22Z", "name": "string", "target_types": [ "string" ], "updated_by": { "avatar": "string", "bot": true, "display_name": "string", "extra_data": { "property1": null, "property2": null }, "flags": [ "string" ], "id": "string", "status": "string", "username": "string" } } ]}GET
Gets the publicly viewable shop items on the list
Success
application/json- response
items?array<>curl -X GET 'https://spider.omniplex.gg/shop/item-benefits'Example Response
{ "items": [ { "created_at": "2019-08-24T14:15:22Z", "created_by": { "avatar": "string", "bot": true, "display_name": "string", "extra_data": { "property1": null, "property2": null }, "flags": [ "string" ], "id": "string", "status": "string", "username": "string" }, "description": "string", "id": "string", "last_updated": "2019-08-24T14:15:22Z", "name": "string", "target_types": [ "string" ], "updated_by": { "avatar": "string", "bot": true, "display_name": "string", "extra_data": { "property1": null, "property2": null }, "flags": [ "string" ], "id": "string", "status": "string", "username": "string" } } ]}GET
Returns the purchase history for an entity.
target_type*stringThe target type of the entity
target_id*stringThe target ID of the entity
Success
application/json- response
items?array<>curl -X GET 'https://spider.omniplex.gg/string/string/shop/purchases'Example Response
{ "items": [ { "cents": 0.1, "created_at": "2019-08-24T14:15:22Z", "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "item_id": "string", "target_id": "string", "target_type": "string" } ]}POST
Spends an entity's earned vote credits on a shop item, optionally discounted by a coupon code. Returns a 204 on success.
header
User-Auth<token>Requires a user token. Should be prefixed with User in Authorization header.
target_type*stringThe target type of the entity
target_id*stringThe target ID of the entity
application/json- body
coupon_code?stringAn optional coupon code to apply to this purchase
item_id?stringSuccess
application/json- response
context?Context of the error. Usually used for validation error contexts
message?stringMessage of the error
curl -X POST 'https://spider.omniplex.gg/string/string/shop/purchase' \ -H 'Content-Type: application/json' \ -d '{}'Example Response
{ "context": { "property1": "string", "property2": "string" }, "message": "string"}