Upload a banner
curl --request POST \
--url https://api.erlcrussia.com/v3/ads/upload \
--header 'Content-Type: image/*' \
--cookie erlc_auth= \
--data '<string>'import requests
url = "https://api.erlcrussia.com/v3/ads/upload"
payload = "<string>"
headers = {
"cookie": "erlc_auth=",
"Content-Type": "image/*"
}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {cookie: 'erlc_auth=', 'Content-Type': 'image/*'},
body: '<string>'
};
fetch('https://api.erlcrussia.com/v3/ads/upload', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.erlcrussia.com/v3/ads/upload",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "<string>",
CURLOPT_COOKIE => "erlc_auth=",
CURLOPT_HTTPHEADER => [
"Content-Type: image/*"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.erlcrussia.com/v3/ads/upload"
payload := strings.NewReader("<string>")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("cookie", "erlc_auth=")
req.Header.Add("Content-Type", "image/*")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.erlcrussia.com/v3/ads/upload")
.header("cookie", "erlc_auth=")
.header("Content-Type", "image/*")
.body("<string>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.erlcrussia.com/v3/ads/upload")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["cookie"] = 'erlc_auth='
request["Content-Type"] = 'image/*'
request.body = "<string>"
response = http.request(request)
puts response.read_body{
"bannerUrl": "https://images.erlcrussia.com/ads/banners/0123456789abcdef.png",
"size": 184320,
"mimeType": "image/png",
"domain": "images.erlcrussia.com",
"path": "ads/banners/0123456789abcdef.png"
}Ads
Upload a banner
Uploads a banner image: up to 5 MB, PNG, JPEG, WebP, GIF or AVIF.
POST
/
ads
/
upload
Upload a banner
curl --request POST \
--url https://api.erlcrussia.com/v3/ads/upload \
--header 'Content-Type: image/*' \
--cookie erlc_auth= \
--data '<string>'import requests
url = "https://api.erlcrussia.com/v3/ads/upload"
payload = "<string>"
headers = {
"cookie": "erlc_auth=",
"Content-Type": "image/*"
}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {cookie: 'erlc_auth=', 'Content-Type': 'image/*'},
body: '<string>'
};
fetch('https://api.erlcrussia.com/v3/ads/upload', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.erlcrussia.com/v3/ads/upload",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "<string>",
CURLOPT_COOKIE => "erlc_auth=",
CURLOPT_HTTPHEADER => [
"Content-Type: image/*"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.erlcrussia.com/v3/ads/upload"
payload := strings.NewReader("<string>")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("cookie", "erlc_auth=")
req.Header.Add("Content-Type", "image/*")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.erlcrussia.com/v3/ads/upload")
.header("cookie", "erlc_auth=")
.header("Content-Type", "image/*")
.body("<string>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.erlcrussia.com/v3/ads/upload")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["cookie"] = 'erlc_auth='
request["Content-Type"] = 'image/*'
request.body = "<string>"
response = http.request(request)
puts response.read_body{
"bannerUrl": "https://images.erlcrussia.com/ads/banners/0123456789abcdef.png",
"size": 184320,
"mimeType": "image/png",
"domain": "images.erlcrussia.com",
"path": "ads/banners/0123456789abcdef.png"
}Was this page helpful?