CNAMES

List CNAME Records

Example Request

curl -i https://api.oktopost.com/v2/cname

Example Result

{  
    "Result":true,
    "Items":[  
        { 
            "Id":"0CN000000000000",
            "Created":"2017-05-17 15:00:00",
            "Modified":"2017-05-17 15:00:00",
            "AccountId": "001000000000001",
            "Name":"ok.oktopost.com"
        }
    ],
    "Total":1
}

Add CNAME Record

Note that all CNAMES must resolve to okt.to.

Example Request

curl -i https://api.oktopost.com/v2/cname -X POST \
-d cname="ok.oktopost.com"

Example Result

{  
    "Result":true,
    "Cname": {  
        "Id":"0CN000000000000",
        "Created":"2017-05-17 15:00:00",
        "Modified":"2017-05-17 15:00:00",
        "AccountId": "001000000000001",
        "Name":"ok.oktopost.com"
    }
}

Update CNAME Record

Example Request

curl -i https://api.oktopost.com/v2/cname/0CN000000000000 -X POST \
-d cname="ok.oktopost.com"

Example Result

{  
    "Result":true,
    "Cname": {  
        "Id":"0CN000000000000",
        "Name":"ok.oktopost.com"
    }
}

Delete CNAME Record

This endpoint will not delete the CNAME record from the DNS but only from Oktopost.

Example Request

curl -i https://api.oktopost.com/v2/cname/0CN000000000000 -X DELETE

Example Result

{  
    "Result":true
}

Feedback and Knowledge Base