How do I use a picture on the API?
There are 3 ways of sending a picture to API:

1. As a binary file. It's the easiest and most convenient way. We provide the code samples for almost all programming languages, so you can choose the sample, copy the code and use it in your project. It's traffic-efficient way and you don't need to upload the image first. The only exception is JavaScript, you better use next two ways when using JavaScript.

2. As Base64-encoded file. Sometimes you can't operate with binary. This way is also very common. It's not as traffic-efficient but it's easier when you use JavaScript. You can get the code of image in Base64 format and send it to the API easily. Very convenient for web-sites.

3. As URL. This way is very convenient when you use images from another website or you've already uploaded the file to the Internet. It's also the fastest method because the connections between two servers is usually faster.

Made on