This article deals with WAPI commands specifically for the WEDOS Protection service. For information on how to set up WAPI and troubleshoot common issues, see the article WAPI – Manual.
This article provides information on the following commands:
- wgp-domain-create – add a domain to WEDOS Protection
- wgp-domain-info – list WEDOS Protection domain information
- wgp-domain-renew – renew service
- wgp-domain-delete – terminate service
- wgp-domain-update-subscription – change subscription plan
- wgp-domain-create-retry – resolve some errors
- wgp-domain-cache-purge – purge WP cache
- wgp-domain-template-replicate – replicates a template to an existing domain
- wgp-domain-templates-list – domain template list
- wgp-services-list – WEDOS Protection domain list
wgp-domain-create
Use the wgp-domain-create request to create a domain record in WEDOS Protection. This request is asynchronous and communicates via notifications ⧉.
Parameters
- domain = domainnév (kötelező)
- variant_id = service plan (required) – 1 = Free, 2 = Advanced, 3 = Expert (you can find the plans and their prices on the product site ⧉)
- period_id = szolgáltatási időszak (kötelező) – 1 = havi, 4 = éves
- upstream_ips = a cél IP-címek tömbje (opcionális) – a cél IP-címekről további információt talál a következőben Protection – Upstream Targets article
- template_domain_id = sablondomain azonosítója (nem kötelező)
- mode = domain mód (nem kötelező)
- ns= a WEDOS NS-t használja (alapértelmezett); a rendszer csak akkor aktiválja a domaint, ha sikeresen ellenőrzi, hogy a WEDOS DNS-t használja.
- cname= lehetővé teszi más szolgáltató DNS-szervereinek használatát, illetve aldomainek hozzáadását CNAME rekorddal; a 3. vagy magasabb szintű domainek módja mindigcname.
You can find more information about adding a domain to WEDOS Protection in the Protection – Add New Domain article.
The default mode for 2nd level domains is ns. Az alapértelmezett és egyetlen elérhető mode for 3rd and higher level domains (subdomains) is cname.
Return Values
- 1000 = OK
- 1001 = Kérés függőben
- 2101 = A paraméterek nem egyeznek
- 2202 = Érvénytelen vagy nem támogatott domainnév-formátum
- 2203 = Érvénytelen period_id
- 2206 = Érvénytelen kérés – belső hiba
- 2272 = Az IP-cím formátuma érvénytelen
- 2273 = Érvénytelen variáns
- 2274 = Belső hiba – hiányzik a user_id paraméter
- 2275 = Belső hiba – a felhasználó nem található
- 2276 = Nem támogatott TLD, vagy a maximális domainszint túllépve
- 2277 = A www. előtag explicit hozzáadása a domainnév elé nem engedélyezett
- 2278 = A domainnév nem használható – ezzel a domainnévvel már létezik szolgáltatás
- 2279 = A kreditszámla zárolva van
- 2280 = A kreditszámla aktív
- 2281 = Inaktív kreditszámla
- 2282 = A kreditszámla pénzneme érvénytelen
- 2283 = Érvénytelen összeg vagy nem elegendő kredit
- 2284 = Hiba a kreditszámla adataiban
- 2285 = Helytelen ÁFA-beállítások
- 2286 = Kreditszámla – belső hiba
- 2290 = Kreditszámla – a tevékenység nem került hozzáadásra a kreditszámlához
- 2291 = A domain már létezik ehhez az ügyfélfiókhoz a WGP API-ban
- 2293 = A kreditszámla egyenlege nem kérdezhető le
- 2294 = A szolgáltatás ára nem kérdezhető le
- 2295 = A domain nem hozható létre a WGP-ben. A fizetés vissza lett vonva.
- 2296 = A kreditszámla mozgása nem vonható vissza
- 2400 = Belső WGP-hiba
- 2401 = A sablon nem alkalmazható a domainre
- 2402 = Érvénytelen domainsablon
- 2403 = A domainsablon és a felhasználó nem egyezik
- 2404 = A domainsablon és a domain csomagja nem egyezik
- 2405 = Elérte a napi sablondomain-limitet
- 2416 = Érvénytelen domainmód
Response Data
- WGP_ID = A WGP domainrekord azonosítója
- domain = domainnév
- order_num = rendelésszám
- currency = a kreditszámla pénzneme
- amount = szolgáltatás ára
- acc_amount_before = a kreditszámla egyenlege a szolgáltatás aktiválása előtt
- acc_amount_current = a kreditszámla egyenlege a szolgáltatás aktiválása után
Notification Response Data
- WGP_ID = A WGP domainrekord azonosítója
- domain = domainnév
- order_num = rendelésszám
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "generated authentication string",
"command": "wgp-domain-create",
"clTRID": "own ID code",
"data": {
"domain": "domain_name.tld",
"variant_id": "1 = Free, 2 = Advanced, 3 = Expert",
"period_id": "1 = monthly billing, 4 = yearly billing",
"upstream_ips": ["IP address 1", "IP address 2", "(optional)"],
"template_domain_id": "ID of the template domain (optional)",
"mode": "domain mode (optional)"
}
}
}
JSON response (request pending):
{
"response": {
"code": 1001,
"result": "Request pending",
"timestamp": "UTF time",
"clTRID": "own ID code",
"svTRID": "server ID code",
"command": "wgp-domain-create",
"data": {
"WGP_ID": "assigned domain ID in WG",
"domain": "domain_name.tld",
"order_num": "order number",
"currency": "currency code",
"amount": "price",
"acc_amount_before": "credit account balance before transaction",
"acc_amount_current": "credit account balance after transaction"
}
}
}
JSON notification after setup is complete:
{
"notify": {
"code": "1000",
"result": "OK",
"timestamp": "UTF time",
"clTRID": "own ID code",
"svTRID": "server ID code",
"command": "wgp-domain-create",
"id": "POLL queue ID",
"data": {
"WGP_ID": "assigned domain ID in WG",
"domain": "domain_name.tld",
"order_num": "order number",
}
}
}
wgp-domain-info
Use the wgp-domain-info request to display domain status information in the WEDOS Protection service.
Parameters
- domain = domainnév (kötelező)
Return Values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2101 = A paraméterek nem egyeznek
- 2202 = Érvénytelen vagy nem támogatott domainnév-formátum
- 2206 = Érvénytelen kérés – belső hiba
- 2292 = A domain nem található ehhez az ügyfélfiókhoz a WGP API-ban
Response Data
- wgp = a domain állapota a WEDOS Protectionben; a state parameter has one of the following values, some of which can contain different data:
- pending_dns = a domain DNS-rekordjainak feloldása folyamatban van
- processing = várakozás a szolgáltatás beállítására
- stuck = várakozás a szoftverkövetelmények teljesülésére
- pending_txt = várakozás a TXT rekord ellenőrzésére (partial template)
- pending_ns = várakozás a névszerverek beállítására (partial template for NS mode and CNAME mode)
- pending_dns_refresh = ismételt DNS-feloldás, ha az előző pending_dns nem talált DNS-rekordot
- pending_crt = várakozás a WG Let’s Encrypt tanúsítványára
- active = a domain aktív (full template)
- service = a domain állapota a WEDOS rendszerében
You can find more detailed information on return data in the template.
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "generated authentication string",
"command": "wgp-domain-info",
"clTRID": "own ID code",
"data": {
"domain": "domain_name.tld"
}
}
}
JSON response (OK, state active):
{
"response": {
"code": 1000,
"result": "ok",
"timestamp": "UTF time",
"clTRID": "own ID code",
"svTRID": "server ID code",
"command": "wgp-domain-info",
"data": {
"wgp":{
"domain": "domain_name.tld",
"domain_id": "assigned domain ID",
"domain_tld": "tld",
"modes": ["režim domény"],
"settings": {
"cache": "cache status (empty off, 1 on)"
},
"url": "https:\/\/client.wedos.global\/protection\/domains\/domain_name.tld",
"state": "active",
"state_data": {
"dns_ip_addresses": ["WG proxy IPv4 address", "WG proxy IPv6 address"],
"dns_pointing_to_proxy": "DNS proxy routing check, empty false, 1 true",
"dns_records_new": [
{
"name": "",
"data": "WG proxy IPv4 address",
"type": "A",
"ttl": 300
},
{
"name": "*",
"data": "WG proxy IPv4 address",
"type": "A",
"ttl": 300
},
{
"name": "",
"data": "WG proxy IPv6 address",
"type": "AAAA",
"ttl": 300
},
{
"name": "*",
"data": "WG proxy IPv6 address",
"type": "AAAA",
"ttl": 300
}
],
"dns_records": [
{
"name": "",
"data": "current IPv4 address",
"type": "A",
"ttl": 300
},
{
"name": "*",
"data": "current IPv4 address",
"type": "A",
"ttl": 300
},
{
"name": "",
"data": "current IPv6 address",
"type": "AAAA",
"ttl": 300
},
{
"name": "",
"data": "current IPv6 address",
"type": "AAAA",
"ttl": 300
}
]
}
},
"service": {
"ID": "service ID in the system",
"name": "domain_name.tld",
"num": "order number",
"user_id": "user ID in the system",
"lang": "language code",
"currency": "currency code",
"cli_legal_type": "Billing - 1 = natural person, 2 = enterpreneur, 3 = legal person",
"cli_company" :"Billing – Company name",
"cli_fname": "Billing – Name",
"cli_lname": "Billing – Surname",
"cli_email": "Billing – Email",
"cli_email2": "Billing – Backup email",
"cli_phone": "Billing – Phone",
"cli_mobile": "Billing – Mobile",
"cli_fax": "Billing – Fax",
"cli_ic": "Billing – Company ID",
"cli_dic": "Billing – VAT ID",
"cli_taxpayer": "Billing – VAT payer (0/1)",
"cli_addr_street": "Billing – Street and number",
"cli_addr_city": "Billing – Town",
"cli_addr_zip": "Billing – ZIP",
"cli_addr_country": "Billing – Country code",
"cli_name_vies": "Billing – VIES name",
"own_legal_type": "Operator - 1 = natural person, 2 = enterpreneur, 3 = legal person",
"own_company": "Operator – Company name",
"own_fname": "Operator - Name",
"own_lname": "Operator - Surname",
"own_email": "Operator - Email",
"own_phone": "Operator - Phone",
"own_ic": "Operator - Company ID",
"own_dic": "Operator - VAT ID",
"own_addr_street": "Operator – Street and number",
"own_addr_city": "Operator - Town",
"own_addr_zip": "Operator - ZIP",
"own_addr_country": "Operator – Country code",
"status": "service status in WEDOS customer administration",
"expiration": "expiration date YYYY-MM-DD"
}
}
}
}
JSON data (OK, state pending_txt):
{
...
"data": {
...
"state": "pending_txt",
"state_data": {
"name": "_TXT_record_name",
"name_formatted": "_TXT_record_name_with_domain.tld",
"value": "TXT-record-value--verification-code"
}
}
}
JSON data (OK, state pending_ns in ns mode):
{
...
"data": {
...
"state": "pending_ns",
"state_data": {
"assigned": [
"assigned-nameserver.ns.wedos.net",
"assigned-nameserver.ns.wedos.com",
"assigned-nameserver.ns.wedos.eu",
"assigned-nameserver.ns.wedos.cz"
],
"assigned_own": [
[
"own-ns1.if-permitted.tld",
"own-ns2.if-permitted.tld"
]
],
"resolved": [
"current-resolved-ns1.domain.tld",
"current-resolved-ns2.domain.tld"
],
"resolved_at": "UTF timestamp of last performed DNS check",
"next_resolve_at": "UTF timestamp of next scheduled DNS check"
}
}
}
JSON data (OK, state pending_ns in cname mode; crt_name and cname are record names and values for the user to set with their DNS provider):
{
...
"state_data": {
"crt_cname": [
{
"name": "_acme-challenge",
"value": "_acme-challenge.verification_code.wgp123.wedos.global"
}
],
"cname": [
{
"name": "*",
"value": "verification_code.wgp123.wedos.global"
},
{
"name": "www",
"value": "verification_code.wgp123.wedos.global"
}
],
"resolved_at": "UTF timestamp of last performed DNS check",
"next_resolve_at": "UTF timestamp of next scheduled DNS check"
}
}
}
wgp-domain-renew
Use the wgp-domain-renew request to extend the domain in the WEDOS Protection service for another period.
Parameters
- service_id = szolgáltatásazonosító (kötelező)
Return Values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2101 = A paraméterek nem egyeznek
- 2152 = A szolgáltatás megújítása le van tiltva
- 2206 = Hiányzó user_id
- 2279 = A kreditszámla blokkolva van
- 2281 = Inaktív kreditszámla
- 2282 = A kreditszámla pénzneme érvénytelen
- 2283 = Érvénytelen összeg vagy nem elegendő kredit
- 2284 = Hiba a kreditszámla adataiban
- 2286 = Kreditszámla – belső hiba
- 2293 = A kreditszámla egyenlege nem kérdezhető le
- 2406 = A domain/szolgáltatás nem található
- 2409 = A szolgáltatás megújítása sikertelen
Response Data
- service_id = szolgáltatásazonosító
- name = Domainnév
- date_from = A szolgáltatás érvényességi dátuma
- date_to = A szolgáltatás lejárati dátuma
- fakt_order_num = A szolgáltatás megújításához tartozó rendelésszám
- currency = A kreditszámla pénzneme
- price = Megújítási ár
- credit = A kreditszámla egyenlege a megújítás után
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "authentication string",
"command": "wgp-domain-renew",
"clTRID": "your ID",
"data": {
"service_id": "service ID"
}
}
}
JSON response (OK):
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF timestamp",
"clTRID": "your ID",
"svTRID": "server ID",
"command": "wgp-domain-renew",
"data": {
"service_id":"service ID",
"domain":"domain_name.tld",
"date_from":"YYYY-MM-DD",
"date_to":"YYYY-MM-DD",
"fakt_order_num":"Order nr.",
"currency":"Currency code",
"price": Amount,
"credit":"Credit account balance"
}
}
}
wgp-domain-delete
Use the wgp-domain-delete command to delete a domain from the WEDOS Protection service.
Parameters
- service_id = szolgáltatásazonosító (kötelező)
- force = A domain törlésének kikényszerítése az A/AAAA domainrekordoktól függetlenül (opcionális, ha van token a DNS-rekordok felülírásához)
Return values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2274 = Belső hiba – hiányzik a user_id paraméter
- 2292 = A domain nem található ebben a felhasználói fiókban
- 2400 = Belső hiba
- 2410 = A szolgáltatás nem található
- 2411 = A DNS felülírásához szükséges token nem érhető el
- 2412 = A DNS átírására irányuló API-kérés sikertelen
- 2413 = A kérés sikertelen, a WGP-nek nincs jogosultsága a DNS frissítésére
- 2414 = A WGP-nek nincs tokenje, és a felhasználó nem állította be a force flaget a WAPI-ban
Response Data
- domain = domainnév
- domain_id = domainazonosító
- wedos_client_id = az ügyfél azonosítója
- service_id = szolgáltatásazonosító
- service_type = szolgáltatás típusa
- wdns_data = az IP-frissítések tömbje
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "authentication string",
"command": "wgp-domain-delete",
"clTRID": "your ID",
"data": {
"service_id": "service ID",
"force": true (forces delete without updating DNS) | false (restores original DNS if able)
}
}
}
JSON response (OK):
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF timestamp",
"clTRID": "your ID",
"svTRID": "server ID",
"command": "wgp-domain-delete",
"data":{
"domain":"domain_name.tld",
"domain_id": id,
"wedos_client_id":"id",
"service_id":id,
"service_type":"hosting_wedos_protection",
"wdns_data":{
"domain":"domain_name.tld",
"rows_a":{
"rem":{
"removed A record ID":{
"name":"removed A record name",
"ttl":"removed A record TTL",
"rdtype":"A",
"rdata":"removed A record IP"
}
},
"add":{
"added A record ID":{
"name":"added A record name",
"ttl":"added A record TTL",
"rdtype":"A",
"rdata":"added A record IP"
}
},
"stay":[ "list of unchanged addresses" ]
},
"rows_aaaa":
"rem":{
"removed AAAA record ID":{
"name":"removed AAAA record name",
"ttl":"removed AAAA record TTL",
"rdtype":"AAAA",
"rdata":"removed AAAA record IP"
}
},
"add":{
"added AAAA record ID":{
"name":"added AAAA record name",
"ttl":"added AAAA record TTL",
"rdtype":"AAAA",
"rdata":"added AAAA record IP"
}
},
"stay":[ "list of unchanged addresses" ]
}
}
}
}
}
wgp-domain-delete-order
Use the wgp-domain-delete command to delete a domain order from the WEDOS Protection service. This is useful for deleting services which failed during creation.
This request will not delete existing services. For those, use wgp-domain-delete.
Parameters
- domain = domainnév (kötelező)
Return values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2274 = Belső hiba – hiányzik a user_id paraméter
- 2292 = A domain nem található ebben a felhasználói fiókban
- 2400 = Belső hiba
- 2410 = A szolgáltatás nem található
- 2421 = A WGP szolgáltatás létezik, a domain nem lesz törölve
Response Data
- domain = domainnév
- domain_id = domainazonosító
- wedos_client_id = az ügyfél azonosítója
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "authentication string",
"command": "wgp-domain-delete-order",
"clTRID": "your ID",
"data": {
"domain": "domain_name.tld"
}
}
}
JSON response (OK):
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF timestamp",
"clTRID": "your ID",
"svTRID": "server ID",
"command": "wgp-domain-delete-order",
"data":{
"domain":"domain_name.tld",
"domain_id": id,
"wedos_client_id":"id"WGP service exists, the domain will not be deleted
}
}
}
JSON response (Error – WEDOS Protection service already exists):
{
"response": {
"code": 2421,
"result": "WGP service exists, the domain will not be deleted",
"timestamp": "UTF timestamp",
"clTRID": "your ID",
"svTRID": "server ID",
"command": "wgp-domain-delete-order"
}
}
wgp-domain-update-subscription
Use the wgp-domain-update-subscription request to change the plan or billing period of the WEDOS Protection service.
Parameters
- service_id = szolgáltatásazonosító (kötelező)
- new_variant_id = service plan (required) – 1 = Free, 2 = Advanced, 3 = Expert
- new_period_id = számlázási időszak (kötelező) – 1 = havi, 4 = éves
Return Values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2101 = A paraméterek nem egyeznek
- 2203 = Érvénytelen period_id
- 2273 = Érvénytelen variáns
- 2293 = a kredit értéke nem kérdezhető le
- 2294 = a szolgáltatás ára nem kérdezhető le
- 2279 = a kreditszámla zárolva van
- 2281 = inaktív kreditszámla
- 2282 = a kreditszámla pénznemével nem lehet fizetni
- 2283 = érvénytelen összeg vagy nem elegendő fennmaradó kredit
- 2284 = a kreditszámla kapcsolattartói adatai érvénytelenek
- 2285 = érvénytelen ÁFA-számlázás
- 2286 = kreditszámla – ismeretlen válaszkód
- 2400 = Belső WGP-hiba
- 2406 = A domain/szolgáltatás nem található
- 2408 = Hiányzó variant_id vagy period_id
Response Data
- domain = domainnév
- domain_id = domainazonosító
- wedos_client_id = az ügyfél azonosítója
- service_id = szolgáltatásazonosító
- service_type = szolgáltatás típusa
- variant_id = szolgáltatáscsomag azonosítója
- period_id = a számlázási időszak azonosítója
- dirty = jelölőnégyzet frissítése (0 = mint korábban, 1 = módosítva)
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "authentication string",
"command": "wgp-domain-update-subscription",
"clTRID": "your ID",
"data": {
"service_id": "service ID",
"new_variant_id": "1, 2, or 3",
"new_period_id": "1, or 4"
}
}
}
JSON response (OK):
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF timestamp",
"clTRID": "your ID",
"svTRID": "server ID",
"command": "wgp-domain-update-subscription",
"data":{
"domain": "domain_name.tld",
"domain_id": domain ID,
"wedos_client_id": "customer ID",
"service_id": service ID,
"service_type": "service type ID",
"variant_id": plan ID,
"period_id": billing period ID,
"dirty": 0|1
}
}
}
wgp-domain-create-retry
With the wgp-domain-create-retry command, you repeat the request to issue a certificate. You can use it to resolve the error_crt status returned by the wgp-domain-info command.
Parametry
- domain = domainnév (kötelező)
Return Values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2292 = A domain nem található ebben a felhasználói fiókban
- 2400 = Belső hiba
- 4000 = Belső hiba
Response Data
- domain = Domainnév
- domain_id = Domainazonosító a WGP-ben
- wedos_client_id = Ügyfélazonosító
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "authentication string",
"command": "wgp-domain-create-retry",
"clTRID": "your ID",
"data": {
"domain": "nazev_domeny.tld"
}
}
}
JSON response (OK):
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF timestamp",
"clTRID": "your ID",
"svTRID": "server ID",
"command": "wgp-domain-create-retry",
"data":{
"domain": "domain_name.tld",
"domain_id": domain ID,
"wedos_client_id": "customer ID"
}
}
}
wgp-domain-cache-purge
Use wgp-domain-cache-purge to purge the WEDOS Protection domain cache.
Parameters
- service_id = Szolgáltatásazonosító (kötelező)
- service_type = Szolgáltatástípus (opcionális)
- values: hosting_wedos_protection (default), hosting_domain
- limiter_decay = Blokkolási idő másodpercben (nem kötelező)
- default value 5
- limiter_reset = Limiter megszakítása (nem kötelező)
- 0 (nem, alapértelmezett), 1 (igen)
Return Values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2101 = A paraméterek nem egyeznek
- 2274 = belső hiba – hiányzó user_id
- 2400 = belső hiba – ismeretlen visszatérési kód
- 2406 = a domain/szolgáltatás nem található
- 2415 = a limiter értéke elérve
- 4000 = rendszerhiba
Response Data
- domain = Domainnév
- domain_id = Domainazonosító
- domain_tld = Domain TLD-je
- service_id = Szolgáltatásazonosító
- wedos_client_id = Ügyfélazonosító
- limiter_available_in = Az az idő másodpercben, amely után a funkció ismét elérhető lesz
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "generated authentication string",
"command": "wgp-domain-cache-purge",
"clTRID": "own ID code",
"data": {
"service_id": Service ID,
"service_type": "service type code (optional)",
"limiter_decay": limiter timeout (in seconds, optional),
"limiter_reset": 0|1 (optional)
}
}
}
JSON response (OK):
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF time",
"clTRID": "own ID code",
"svTRID": "server ID code",
"command": "wgp-domain-cache-purge",
"data":{
"domain":"domain_name.tld",
"domain_id": domain ID,
"domain_tld":"tld",
"wedos_client_id":"customer account ID"
}
}
}
wgp-domain-template-replicate
Use the wgp-domain-template-replicate request to change the target domain settings according to the selected template domain.
To create a template, follow the guide in the article Protection – Templates. Jelenleg nem hozhat létre sablonokat a WAPI-n keresztül.
Parameters
- service_id – service ID (required)
- template_domain_id – target template domain ID (required)
- service_type – service type (optional)
- values: hosting_domain, hosting_wedos_protection
Return values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2101 = A paraméterek nem egyeznek
- 2400 = Belső WGP-hiba
- 2401 = A sablon nem alkalmazható a domainre
- 2402 = Érvénytelen domainsablon
- 2403 = A domainsablon és a felhasználó nem egyezik
- 2404 = A domainsablon és a domain csomagja nem egyezik
- 2405 = Elérte a napi sablondomain-limitet
- 2406 = A domain/szolgáltatás nem található
- 2407 = A sablondomain nem található
- 4000 = Belső hiba
Response Data
- domain = domainnév
- domain_id = domainazonosító
- service_id = szolgáltatásazonosító
- service_type = szolgáltatás típusa
- template_domain_id = sablondomain azonosítója
- replications_count = elvégzett replikációk száma
- replications_limit = replikációk maximális száma
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "authentication string",
"command": "wgp-domain-template-replicate",
"clTRID": "your ID",
"data": {
"service_id": service ID,
"template_domain_id": template domain ID,
"service_type": "hosting_domain, or hosting_wedos_protection (optional)"
}
}
}
JSON response (OK):
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF timestamp",
"clTRID": "your ID",
"svTRID": "server ID",
"command": "wgp-domain-template-replicate",
"data":{
"domain":"domain_namey.tld",
"domain_id": domain ID,
"service_id": service ID,
"service_type": "service type",
"template_domain_id": template domain ID,
"replications_count": replication count,
"replications_limit": replication limit
}
}
}
wgp-domain-templates-list
Use the wgp-domain-templates-list request to retrieve a list of template domains for the selected WEDOS Protection plan.
To create a template, follow the guide in the article Protection – Templates. Jelenleg nem hozhat létre sablonokat a WAPI-n keresztül.
Parameters
- variant_id = a csomag azonosítója (kötelező)
- per_page = Oldalankénti rekordok száma (alapértelmezett = 15, az összes rekord lekérése = -1) (opcionális)
- page = Oldalszám (alapértelmezett = 1) (opcionális)
- locale = Nyelv (alapértelmezett = en, támogatott = cs, en) (opcionális)
- search = Keresés a custom_name és name oszlopokban (opcionális)
Return Values
- 1000 = OK
- 2100 = Hiányzó kötelező paraméter
- 2400 = belső hiba
- 4000 = belső hiba
Response Data
- data = A sablondomainek listája
- id = sablondomain azonosítója
- custom_name = A sablondomain neve (a felhasználó által megadva)
- name = A sablondomain neve (rendszerszintű)
- url = A sablondomain URL-je
- first_page_url = A lista első oldalának URL-je
- from = Lapozás kezdete
- last_page = Az utolsó oldal száma
- last_page_url = Az utolsó listaoldal URL-je
- links = Lapozási hivatkozások tömbje
- url = link URL-je
- label = Gomb felirata
- active = null|1
- next_page_url = A következő oldal URL-je
- path = A sablondomainek listájának URL-je
- per_page = Oldalankénti bejegyzések száma
- prev_page_url = Az előző oldal URL-je
- to = Lapozás vége
- total = Az oldalak teljes száma
Templates
JSON request:
{
"request": {
"user": "your@login.tld",
"auth": "authentication string",
"command": "wgp-domain-templates-list",
"clTRID": "your ID",
"data": {
"variant_id": plan ID 1 = Free, 2 = Advanced, 3 = Expert,
"per_page": entries per page (optional),
"page": page nr. (optional),
"locale": "cs, or en (optional)",
"search": "Search by custom_name, name (optional)"
}
}
}
JSON response (OK):
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF timestamp",
"clTRID": "your ID",
"svTRID": "server ID",
"command": "wgp-domain-templates-list",
"data":{
[
{
"id": Template domain ID,
"custom_name":"termplate domain user name",
"name":"system-name.template",
"url":"https:\/\/template.domain.url\/system-name.template"
}
],
"first_page_url":"https:\/\/first.page.url",
"from": 1st page number,
"last_page": last page number,
"last_page_url":"https:\/\/last.page.url",
"links":[
{
"url": "https:\/\/page.url",
"label":"Button label",
"active": null|1
}
],
"next_page_url": "https:\/\/next.page.url",
"path":"https:\/\/list.url",
"per_page": entries per page,
"prev_page_url":"https:\/\/previous.page.url",
"to": last list item,
"total": total page count
}
}
}
wgp-services-list
With the wgp-services-list request, you can retrieve a list of domains with the WEDOS Protection service. You can filter by status.
The wgp-services-list only lists domains that have been added as services. For domains added in B2B mode, this only happens once the domain is fully set up. Until then, you can use the wgp-domain-info command to check that domain’s status.
Parameters
- status = szolgáltatás állapota (nem kötelező)
Return Values
- 1000 = OK
- 2206 = Érvénytelen kérés – belső hiba
Response Data
- ID = a domain rekordjának azonosítója
- name = domainnév
- status = szolgáltatás állapota
- expiration = A WG szolgáltatás lejárati dátuma
Templates
JSON request
{
"request": {
"user": "your@login.tld",
"auth": "generated authentication string",
"command": "wgp-services-list",
"clTRID": "own ID code",
"data": {
"status": "active, expired, disabled or deleted"
}
}
}
JSON response (OK)
{
"response": {
"code": 1000,
"result": "OK",
"timestamp": "UTF time",
"clTRID": "own ID code",
"svTRID": "server ID code",
"command":"wgp-services-list",
"data":{
"service ID in the system":{
"ID":"service ID in the system",
"domain":"domain_name.tld",
"status":"service status",
"expiration": "expiration date YYYY-MM-DD"
}
}
}