Retire Sales Tracking Code

Retire a Sales Tracking Code.

In order to retire a Sales Tracking Code, it must assigned to at least one customer.
If the Sales Tracking Code has never been used, it must be deleted instead of retired.

Path Parameters

SalesTrackingCodeIdIntegerThe Fusebill Generated ID of the sales tracking code
curl –X POST \ 
  -H "Authorization: Basic {APIKey}" \
//Setup API key 
string apiKey = "{APIKey}"; 
//Configure URI 
WebRequest request = WebRequest.Create("HTTPS://"); 
//Add Api key authorization 
request.Headers.Add(HttpRequestHeader.Authorization, "Basic "+apiKey); 
//Set request method 
request.Method = "POST"; 
//Perform the request 
var httpResponse = (HttpWebResponse)request.GetResponse(); 
//Record the response from our request 
var result = ""; 
using (var streamReader = new StreamReader(httpResponse.GetResponseStream())) 
  result = streamReader.ReadToEnd(); 
#Import library JSON 
import json 
#Import library Requests 
import requests 
#Pass in a dictionary to the Headers parameter 
headers = {'Authorization' : 'Basic {APIKey}'} 
#Pass in your URI, Payload and Headers 
r ='' headers=headers) 
This request does not have a JSON payload.
    "type": "Sales Tracking Code Z",
    "code": "123",
    "name": "Bob Smith",
    "description": "sample string sample sting",
    "email": "[email protected]",
    "status": "Retired",
    "deletable": false,
    "id": 35397,
    "uri": ""
    "ErrorId": 0,
    "HttpStatusCode": 404,
    "Errors": [
            "Key": "Api Error",
            "Value": "SalesTrackingCode with id 3666492 not found."