arrow-up-from-bracketUpload

Learn how to upload assets with a query.

Upload content entry

POST https://api.echo3D.com/upload

This endpoint allows you to upload or edit assets.

Headers

Name
Type
Description

Content-Type

string

Use multipart/form-data when uploading multiple files.

Request Body

Name
Type
Description

key*

string

Target collection key eg some-words-1234

email*

string

Your email address

userKey*

string

Your authentication key

file*

binary

The asset file associated with your request. Not required if using url

url*

string

The source url for the asset or AR target file. Not required if using file

target_type

integer

AR target type, defaults to 2 (BRICK / no target) if not specified. Options: 0 for IMAGE_TARGET, 1 for GEOLOCATION_TARGET, or 2 for BRICK_TARGET. See additional info about AR targets below.

data

string

A string representing metadata to add to the uploaded content. Format: key1:value1;key2:value2;...

secKey

string

Collection Security Key. Only if enabled through the Security page.

allowDuplicate

boolean

Set to true to allow duplicate uploads. Duplicates are detected via an md5 checksum of the uploaded file

noProcessingWait

boolean

By default, Server waits up to 5 minutes for asset processing to complete before responding with complete asset object data. Include noProcessingWait=true in your request to prompt server to respond with basic asset data when asset is first saved to your collection. Processing times vary according to file size, platform load and asset format. Includes conversions to web-friendly formats and 3D model screenshots.

Target Type

Target types can be one of the following:

0 for IMAGE_TARGET

If you choose to use an image as your AR target, you must also add to your request one of the following:

  • url_image: A URL to the image you want to use as a target

  • file_image: The image file you want to use as a target. The file will be uploaded as Part.

1 for GEOLOCATION_TARGET

A location target must be associated with a location. You must either send an address or send location coordinates (longitude and latitude):

  • text_geolocation: Address for the location.

  • longitude and latitude: Longitude and latitude coordinates

2 for BRICK_TARGET

A surface target; needs no additional arguments.

Examples

Here are a few upload API examples using Postmanarrow-up-right.

  1. Uploading an asset from a url

  1. Uploading an asset from a local file on your PC

  1. Uploading a model asset on a brick target from a third-party search engine:

  • type is search, source is Sketchfab, and url includes an URL redirecting to the model

  • hologram_type is 2

  • target_type is 2

Uploading with Metadata

You can attach a .csv file that contains pairs of keys and values to the Upload API call to be added alongside the uploaded asset as data entries. Your request must include:

  • file_csv that includes a file

Your metadata file should contain only two columns: one for keys and the second for values.

Here is a sample file you can use:

file-download
60B

Overwrite or Edit an Existing Entry

You can overwrite or edit an existing entry that was previously uploaded by using the upload API with a few additional parameters. Your request must include:

  • edit_type that included the type of edit to make: hologram or target.

  • entryId that included the Entry ID of the existing Entry to overwrite.

Batch Upload

If you would like to upload many assets at once, the following repository allows for customized batch uploads via a Python script and a CSV data file. Click herearrow-up-right to access the repository on GitHub.

Last updated