SoulFire LogoSoulFire

Query blocks

POST
/v1/instances/{instance_id}/bots/{bot_id}/world/blocks:query

Authorization

AuthorizationBearer <token>

Preferred API authentication. Use a JWT with the api audience.

In: header

Path Parameters

instance_id*string
Formatuuid
bot_id*string
Formatuuid

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

region?
selector?
sort?soulfire.v1.QuerySort

Value in

  • "QUERY_SORT_UNSPECIFIED"
  • "QUERY_SORT_NEAREST"
  • "QUERY_SORT_FARTHEST"
  • "QUERY_SORT_XYZ"
pageSize?integer
Formatint64
Range0 <= value <= 4294967295
pageToken?string

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/bots/497f6eca-6276-4993-bfeb-53cbbbba6f08/world/blocks:query" \  -H "Content-Type: application/json" \  -d '{}'
{  "blocks": [    {      "position": {        "x": 0,        "y": 0,        "z": 0,        "dimension": "string"      },      "blockId": "string",      "properties": {        "property1": "string",        "property2": "string"      },      "blockEntity": {},      "biomeId": "string",      "skyLight": 0,      "blockLight": 0,      "hardness": 0.1,      "diggable": true,      "replaceable": true,      "solid": true,      "interactive": true,      "effectiveToolTags": [        "string"      ],      "fluid": {        "fluidId": "string",        "source": true,        "height": 0.1      },      "collisionShape": {        "boxes": [          {            "minimum": {              "x": 0.1,              "y": 0.1,              "z": 0.1            },            "maximum": {              "x": 0.1,              "y": 0.1,              "z": 0.1            }          }        ]      },      "interactionShape": {        "boxes": [          {            "minimum": {              "x": 0.1,              "y": 0.1,              "z": 0.1            },            "maximum": {              "x": 0.1,              "y": 0.1,              "z": 0.1            }          }        ]      },      "chunkRevision": "string"    }  ],  "nextPageToken": "string",  "worldRevision": "string"}

How is this page?