πŸ“„Documentation

Welcome to the Anything World API!

You can use the Anything World's API in your application to request 3D models and other data based on different search criteria.

Python users can also use a package directly for easier integration. It's available at https://pypi.org/project/anything-world/ and can be installed with pip install anything-world.

API reference

API key

After generating the API key in our Dashboard, the API key can be used to authorize requests to the Anything World's API.

Bear in mind that many endpoints require the API to generate results.

General Format

https://api.anything.world/anything?key=<API_KEY>&name=<NAME>

Example

https://api.anything.world/anything?key=<API_KEY>&name=bird

The API is currently experimental and is subject to change. For use in a critical production environment, please reach out to us at hello@anything.world.

3D Model Library

The following requests can be used to download 3D models from our library. Those are the same models available in our gallery. Here you can find models animated by our AI pipeline as well as static ones, and they are ideal for creating new games or entire 3D worlds without having to design nor animate by hand.

​Get a specific model by name

GET https://api.anything.world/anything?key=<API_KEY>&name=<NAME>

​Get a specific model by name

GET https://api.anything.world/anything?key=<API_KEY>&name=<NAME>

Retrieve a single model (JSON response) based on its name. If there is an exact match it will be returned, otherwise a similar result (if found), or no model otherwise.

Query Parameters

NameTypeDescription

key*

String

API key

name*

String

Name to search, e.g. dog

fuzzy

Boolean

Whether to enable approximate matching (true by default)

{
"_id": "5e958b911c9d440000f9771d",
"name": "dog",
"creature": "dog",
"group": "mammals",
"type": "quadruped",
"behaviour": "walk",
"pet": true,
"detail": "medium",
"model": {
"parts": {
"body": "https://assets.anything.world/dog/body.obj?Expires=1629890114&KeyName=models&Signature=phbXMpLsJBzNDTXQAdJW7phnvSg",
"head": "https://assets.anything.world/dog/head.obj?Expires=1629890114&KeyName=models&Signature=h6t0BWNXhCoB3DXP0-eNnKULCJQ",
"leg_front_left_bot": "https://assets.anything.world/dog/leg_front_left_bot.obj?Expires=1629890114&KeyName=models&Signature=K9W3wfPT9WhpCH6jZXRRnVMN7G4",
"leg_front_left_top": "https://assets.anything.world/dog/leg_front_left_top.obj?Expires=1629890114&KeyName=models&Signature=AfTkg0KIlEWw-CFtJM0yLcrVVCw",
"leg_front_right_bot": "https://assets.anything.world/dog/leg_front_right_bot.obj?Expires=1629890114&KeyName=models&Signature=TcYVhFISHsV1FWtu0OVdSe0rYQU",
"leg_front_right_top": "https://assets.anything.world/dog/leg_front_right_top.obj?Expires=1629890114&KeyName=models&Signature=GP8CokHpOUM93kbzv9rhWWWrAxY",
"leg_hind_left_bot": "https://assets.anything.world/dog/leg_hind_left_bot.obj?Expires=1629890114&KeyName=models&Signature=Xit_bZ8J7IiVY8EqO4cQLw-7twU",
"leg_hind_left_top": "https://assets.anything.world/dog/leg_hind_left_top.obj?Expires=1629890114&KeyName=models&Signature=2PASF7b7Tj-JPARj80hPAzuxohM",
"leg_hind_right_bot": "https://assets.anything.world/dog/leg_hind_right_bot.obj?Expires=1629890114&KeyName=models&Signature=OqWkuXy9sqiOcpqd9vGBb8PNAOo",
"leg_hind_right_top": "https://assets.anything.world/dog/leg_hind_right_top.obj?Expires=1629890114&KeyName=models&Signature=c7ZU1jQz-GyamcYyjVYlaPfjpcM",
"tail": "https://assets.anything.world/dog/tail.obj?Expires=1629890114&KeyName=models&Signature=CBsGk-k-zL096jbaCdip7Rr0tt8"
},
"other": {
"material": "https://assets.anything.world/dog/dog.mtl?Expires=1629890114&KeyName=models&Signature=y7vPL9ZbY0QJwLZuVGkThNBu8x0",
"model": "https://assets.anything.world/dog/dog.obj?Expires=1629890114&KeyName=models&Signature=qnIGLYo3mXN2NnVMhuWOBMxxKOU",
"texture": [
"https://assets.anything.world/dog/basecolor.png?Expires=1629890114&KeyName=models&Signature=oNIXgYIHMletKl009yrow_zkAHk"
],
"reference": "https://assets.anything.world/dog/reference.png?Expires=1629890114&KeyName=models&Signature=EF1MrK08ZLGpguI_8r-kCwysWcM"
}
},
"author": "Poly by Google",
"source": "AW-API",
"forest": false,
"beach": false,
"city": true,
"desert": false,
"farm": false,
"sea": false,
"icescape": false,
"jungle": false,
"lake": false,
"pond": false,
"river": false,
"swamp": false,
"grass": false,
"rural": true,
"urban": false,
"garden": true,
"scale": {
"height": "1.2m"
},
"source_endpoint": "aw_api"
}

Get all models matching the query

GET https://api.anything.world/anything?key=<API_KEY>&search=<QUERY>

Query Parameters

NameTypeDescription

key*

String

7G3ym6OHJWQd

name*

String

1SKLq9zbFhWX

fuzzy

Boolean

AyBg9FLvHlnr

Get all models matching the query

GET https://api.anything.world/anything?key=<API_KEY>&search=<QUERY>

Get a JSON array representing all models that matched the query string, which can be anything, such as a name (e.g. "cat"), a tag (e.g. "Christmas"), a habitat (e.g. "jungle" or "desert") or a taxonomical category (e.g. "animal" or "object").

Query Parameters

NameTypeDescription

key*

String

Your API key

search*

String

Search query

fuzzy

Boolean

Whether approximate matches are returned (default is true)

{
    // Response
}

Query Parameters

NameTypeDescription

key*

String

3d3V9BS6Ui1J

search*

String

yR8Ncs03Mso0

fuzzy

Boolean

hQ8gSwUxMy6r

AI Model Processing

These requests give you access to our AI pipeline. With them you'll be able to animate your own 3D models. To know which types of models we support and other requirements that should be followed to have a proper animation, please refer to this page.

Automatically animate a given 3D model

POST https://api.anything.world/animate

Automatically animate a given 3D model

POST https://api.anything.world/animate

Get a JSON response with a "model_id" representing an unique identifier for the 3D model being animated. It’s important to note that, because we’re sending files through the request, all parameters and files should be encoded as formdata.

The files should be sent as the value of the files key, no matter the amount of files. As value, a list of tuples should be provided with each tuple containing: (file_name, file_content, content_type). The file names should have the expected extension and content-type. Currently we support the following file types:

Meshes: OBJ, GLB, GLTF, FBX and DAE

Materials: MTL

Textures: JPG, PNG, BMP, GIF, TIF, TGA and TARGA

As content-type, please make sure your files have the expected one:

Make sure that all your mesh, materials and texture files are referencing each other as expected. For example, a material file named "foo.mtl" should be properly referenced inside a "model.obj". The rule of thumb is: if you are able to open your model in a 3D editor like Blender and it shows all expected materials and textures bindings, it should work with our API as well.

It's also possible to send a ZIP file as your model data. Please make sure to include all the files in a single folder (please, don't use subfolders e.g. for materials, etc) and compress it as a valid .zip file (with the right content-type).

This request is asynchronous and follows a polling strategy, meaning that a response will be returned by the endpoint as fast as possible (in a few seconds). The animation process though takes time (approx. 10 minutes). Please, use the generated "model_id" as parameter for a request to https://api.anything.world/user-processed-model endpoint to get the current status of the model being animated. When the request returns the final stage, the model should have been animated with success and the generated rigged files will be available to download. Please check the documentation for the https://api.anything.world/user-processed-model endpoint, it's just bellow, in the next section.

To better illustrate this process, we provide an open source Python library that can be used as example on how to communicate with our API: https://github.com/anythingworld/anything-world-python. Given it has minimal requirements, this implementation can be easily translated to other programming languages.

It's important to note that you have a free allowance of model processing credits which renews every month. Additional credits can be purchased in your profile page.

Request Body

NameTypeDescription

key*

String

Your API key

model_name*

String

A name to be given to the model

model_type*

Type of the given model (e.g. "cat")

can_use_for_internal_improvements

String

"true" if user allows AW to use the model for internal improvements (ML training, etc) and "false" otherwise. If not specified, it defaults to "false"

author

String

Name of the author of the model. If not specified, it defaults to an empty string

license

String

License attributed to the model. Either "cc0", "ccby" or "mit". If not specified, it defaults to "ccby"

symmetry*

String

"true" if the model is symmetric, "false" otherwise

files*

String

Files to be sent to be animated, encoded as a list of tuples like (file_name, file_content, content_type).

{
    // Response
}

Get the state of a model processed by the AI pipeline

GET https://api.anything.world/user-processed-model?key=<API_KEY>&id=<MODEL_ID>&stage=<MODEL_STAGE>

Request Body

NameTypeDescription

api_key*

String

jrLlBxx9D0dQ

model_name*

String

f9ddW0nDB1i3

model_type*

HdqtuhytrwhD

can_use_for_internal_improvements

String

tfXk3loKIZma

author

String

fXOhLER65UsI

license

String

KXS1IXKgUsYy

symmetry*

String

Co2IApCU0b0M

files*

String

Xolefz5WmMUk

Get a model state processed by the AI pipeline

GET https://api.anything.world/user-processed-model?key=<API_KEY>&id=<MODEL_ID>&stage=<MODEL_STAGE>

Get a JSON response representing the current state of a model being processed by the AI pipeline. If a model has completed the stage specified in the query (or is fully processed if the stage is not given), the response will be a model entry in similar format as the returned JSON of https://api.anything.world/anything endpoint. An error is returned if the model faced a processing error or if the model has not reached yet the asked stage or is past it.

Note that you can speed up your request by setting the stage parameter in a strategic manner, depending on your use case:

  • If you don't need other formats than the basic ones provided, you don't need to specify a stage parameter (or specify stage="done"). This way you'll receive a .obj file for static and vehicle models; and .fbx and .glb for animated models. Our AI pipeline will return the models as soon as they are processed, however it will keep performing formats conversion and thumbnails generation on background, and the stage of the model will change for formats_conversion_finished and thumbnails_generation_finished when those operations are done. This is the preferred way to get a result as fast as possible;

  • If you care about having the results in .fbx and .glb for static and vehicle models as well as .dae and .gltf formats for all models, please request with stage="formats_conversion_finished". This will take longer to your request to finish, but you'll be able to have extra formats. You will still get some speed up by not having to wait for thumbnails generation to finish;

  • If you want to receive not only the extra formats but also thumbnail images representing previews of the 3D model, please use stage="thumbnails_generation_finished". This is the longest request and will not give you any speed up when compared with the other previous options.

Within the JSON structure, the model rig sub-object can be found in model.rig. At its raw level, you can find the rigged mesh file in the formats cited above, e.g. model.rig.FBX contains the FBX version of the rig. The animations can be found in model.rig.animations, with a sub-object in the JSON for each animation, and inside that, a field for each format, e.g. model.rig.animations.walk.FBX contains the walk animation (only available for some categories) in FBX format. If the model is not rigged and animated but a vehicle, you can find the separated parts in the model.parts sub-object in the JSON response.

It's important to note that you have a free allowance of model processing credits which renews every month. Additional credits can be purchased in your profile page.

Query Parameters

NameTypeDescription

key*

String

Your API key

id*

String

Model id (returned by the https://api.anything.world/animate endpoint, for instance)

stage

String

Stage to check. The model JSON will only be returned if the stage is exactly matched. If not specified, it only checks to see if the model is fully processed.

{
    // Response
}

Get all models processed by the AI pipeline for the user

GET https://api.anything.world/user-processed-models?key=<API_KEY>

Get a JSON response with an array of data from all the models processed with the AI pipeline by the user.

Each element of the array follows the same format of a processed model (rigged and animated model if the category allowed, otherwise part-split vehicle or static mesh) as described in the endpoint user-processed-model (which you can check for more context, just note that in the endpoint described now you do not have the further control of the stage parameter).

Within the JSON structure of an element of the array (that is, a processed model), the rig data sub-object can be found in model.rig. At its raw level, you can find the rigged mesh file in the formats cited above, e.g. model.rig.FBX contains the FBX version of the rig. The animations can be found in model.rig.animations, with a sub-object in the JSON for each animation, and inside that, a field for each format, e.g. model.rig.animations.walk.FBX contains the walk animation (only available for some categories) in FBX format. If the model is not rigged and animated but a vehicle, you can find the separated parts in the model.parts sub-object in the JSON response.

It's important to note that you have a free allowance of model processing credits which renews every month. Additional credits can be purchased in your profile page.

Query Parameters

NameTypeDescription

key*

String

Your API key

{
    // Response
}

By default, this request will make sure to check if a model is successfully processed and it will generate the animations in .glb, .gltf, .fbx and .dae formats. It's also possible to speed up the request by setting the stage="format_conversion". This will only generate the .glb and .fbx formats, but will reduce the processing duration, speeding up your request.

It's important to note that you have a free allowance of model processing credits which renews every month. Additional credits can be purchased in

Query Parameters

NameTypeDescription

key*

String

QP4fYJWixVgt

id*

String

6cnJ5bVNtoQb

stage

String

T3TMK85ytzgk

Last updated