{ "openapi": "3.0.0", "info": { "title": "5centsCDN - Accounts", "description": "API for managing Account in 5centsCDN", "version": "2.0.0", "contact": { "email": "help@5centscdn.com" }, "license": { "name": "Apache 2.0", "url": "http://www.apache.org/licenses/LICENSE-2.0.html" }, "x-jentic-source-url": "https://api.swaggerhub.com/apis/5centscdnInc/5centsCDN-Accounts/2.0.0/swagger.json" }, "servers": [ { "url": "https://api.5centscdn.com/v2", "description": "5centsCDN API Server - Production" } ], "paths": { "/account/dv": { "get": { "tags": [ "Domain Verification" ], "summary": "List Domains", "description": "List Domains", "operationId": "DomainList", "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "domains": { "type": "array", "items": { "$ref": "#/components/schemas/domainList" } } } } } } } } }, "post": { "tags": [ "Domain Verification" ], "summary": "Create Domain", "description": "Create a Domain", "operationId": "createDomain", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/createDomain" } } } }, "deprecated": false, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "message": { "type": "string" }, "domain": { "type": "array", "items": { "$ref": "#/components/schemas/domainList" } } } } } } } } } }, "/account/dv/{domainid}": { "get": { "tags": [ "Domain Verification" ], "summary": "Get Domain", "description": "Returns the details of a domain verification", "operationId": "getDomain", "parameters": [ { "$ref": "#/components/parameters/domainIdParam" } ], "deprecated": false, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "domain": { "$ref": "#/components/schemas/domainList" } } } } } } } }, "delete": { "tags": [ "Domain Verification" ], "summary": "Delete Domain", "description": "Delete information of a domain verification. To cast request method POST and parameters _METHOD = DELETE", "operationId": "deleteDomain", "parameters": [ { "$ref": "#/components/parameters/domainIdParam" } ], "deprecated": false, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "message": { "type": "string" } } } } } } } } }, "/account/dv/{domainid}/validate": { "get": { "tags": [ "Domain Verification" ], "summary": "Verify Domain", "description": "Verifivation of domain", "operationId": "verifyDomain", "parameters": [ { "$ref": "#/components/parameters/domainIdParam" } ], "deprecated": false, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "msg": { "type": "string" } } } } } } } } }, "/account/ssl": { "get": { "tags": [ "SSL Certificates" ], "summary": "List SSL Certificates", "description": "List SSL certificates", "operationId": "sslCertificatesList", "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "certs": { "type": "array", "items": { "$ref": "#/components/schemas/certList" } } } } } } } } } }, "/account/ssl/new": { "post": { "tags": [ "SSL Certificates" ], "summary": "Create Certificates", "description": "Create a SSL Certificate", "operationId": "createSSL", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/createSSL" } } } }, "deprecated": false, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "message": { "type": "string" }, "cert": { "$ref": "#/components/schemas/certList" } } } } } } } } }, "/account/ssl/{sslcertid}": { "get": { "tags": [ "SSL Certificates" ], "summary": "SSL Certificate", "description": "Return the details of a SSL Certificate", "operationId": "getSSLCertificate", "parameters": [ { "$ref": "#/components/parameters/sslCertIdParam" } ], "deprecated": false, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "cert": { "$ref": "#/components/schemas/certList" } } } } } } } }, "post": { "tags": [ "SSL Certificates" ], "summary": "Update SSL Certificates", "description": "Update the information of SSL certificate", "operationId": "updateSSLCertificates", "parameters": [ { "$ref": "#/components/parameters/sslCertIdParam" } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SSLUpdate" } } } }, "deprecated": false, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "message": { "type": "string" }, "cert": { "$ref": "#/components/schemas/certList" } } } } } } } }, "delete": { "tags": [ "SSL Certificates" ], "summary": "Delete Info", "description": "Delete information of a SSL certificate. To cast request method POST and parameters _METHOD = DELETE", "operationId": "deleteSSL", "parameters": [ { "$ref": "#/components/parameters/sslCertIdParam" } ], "deprecated": false, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "message": { "type": "string" } } } } } } } } }, "/account/bwop": { "post": { "tags": [ "Bandwidth Overage Protection" ], "summary": "Update Bandwidth Overage Protection", "description": "Update the information of bandwidth overage protection", "operationId": "bopUpdate", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/createBop" } } } }, "responses": { "200": { "description": "success", "content": { "application/json": { "schema": { "type": "object", "properties": { "result": { "type": "string", "example": "success" }, "message": { "type": "string" } } } } } } } } } }, "components": { "securitySchemes": { "ApiKeyAuth": { "type": "apiKey", "in": "header", "name": "X-API-Key" } }, "schemas": { "createDomain": { "required": [ "domain" ], "properties": { "domain": { "type": "string", "description": "To specify the domain name.eg: mydomain.com", "example": "mydomain.com" } } }, "domainList": { "properties": { "id": { "type": "integer" }, "serviceid": { "type": "integer" }, "domain": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "updated_at": { "type": "string", "format": "date-time" }, "validated_at": { "type": "string" }, "deleted_at": { "type": "string" }, "validated": { "type": "string" }, "deleted": { "type": "boolean" } } }, "createSSL": { "required": [ "_METHOD", "crt", "key", "name" ], "type": "object", "properties": { "_METHOD": { "type": "string", "description": "To caste method POST to PUT", "example": "PUT" }, "name": { "type": "string", "description": "Name of the SSL certificate" }, "crt": { "type": "string", "description": "Certificate's CRT data.
Which is in tha format ---BEGIN CERTIFICATE---- [certificate's CRT data ] ----END CERTIFICATE----" }, "key": { "type": "string", "description": "SSL Key.
In the format ---BEGIN PRIVATE KEY---- [certificate's key data ] ----END PRIVATE KEY----" }, "cabundle": { "type": "string", "description": "Certificates CA Bundle data.
Which is in the format ---BEGIN CERTIFICATE---- [your certificate's CA bundle data ] ----END CERTIFICATE----" } } }, "SSLUpdate": { "required": [ "crt", "key", "name" ], "type": "object", "properties": { "name": { "type": "string", "description": "Name of the SSL certificate" }, "crt": { "type": "string", "description": "Certificate's CRT data.
Which is in tha format ---BEGIN CERTIFICATE---- [certificate's CRT data ] ----END CERTIFICATE----" }, "key": { "type": "string", "description": "SSL Key.
In the format ---BEGIN PRIVATE KEY---- [certificate's key data ] ----END PRIVATE KEY----" }, "cabundle": { "type": "string", "description": "Certificates CA Bundle data.
Which is in the format ---BEGIN CERTIFICATE---- [your certificate's CA bundle data ] ----END CERTIFICATE----" } } }, "certList": { "properties": { "id": { "type": "integer" }, "name": { "type": "string" }, "crt": { "type": "string" }, "key": { "type": "string" }, "cabundle": { "type": "string" }, "domain": { "type": "string" }, "sans": { "type": "array", "items": { "type": "string" } }, "expiry": { "type": "string", "format": "date" }, "installs": { "type": "integer" }, "expired": { "type": "boolean" } } }, "createBop": { "required": [ "bwop" ], "properties": { "bwop": { "type": "integer", "format": "int32", "description": "To specify the monthly bandiwdth limit (%) enter digit only", "example": 0 } } } }, "parameters": { "domainIdParam": { "name": "domainid", "in": "path", "description": "Id of the Domain Verification", "required": true, "style": "simple", "explode": false, "schema": { "type": "string" } }, "sslCertIdParam": { "name": "sslcertid", "in": "path", "description": "Id of the SSL certificate", "required": true, "style": "simple", "explode": false, "schema": { "type": "string" } } } }, "security": [ { "ApiKeyAuth": [] } ], "tags": [ { "name": "Domain Verification", "description": "endpoints related to Domain Verification" }, { "name": "SSL Certificates", "description": "endpoints related to SSL Certificates" }, { "name": "Bandwidth Overage Protection", "description": "update Bandwidth Overage Protection" } ] }