Update Custom Field on Subscription

This call allows you to edit the value of a Custom Field on a Subscription.

Request Parameters

keyStringThis is the unique key of the Custom Field you wish to modify.
subscriptionIdIntegerThis is the Id of the Subscription in which the Custom Field exists.
ValueStringThis is the value you wish to update the custom field to. This will always be the string version of the value. If you wish to pass a number, for example, pass it as "123". Likewise, a DateTime would be passed as "2014-06-26T04:00:00". We will use the known data type of the custom field to properly convert the String to a Number, DateTime, etc.
curl -X PUT "https://secure.fusebill.com/v1/SubscriptionCustomFields" \
	-H "Content-Type: application/json" \
	-H "Authorization: Basic {APIKey}" \
	-d "{key:'Color',subscriptionId:{subscriptionId},Value:'Red'}"
//Json Payload
string jsonData = "{key:'{key}',subscriptionId:{subscriptionId},Value:'Custom Field Update'}";
//Setup API key
string apiKey = "{APIKey}";
//Configure URI
WebRequest request = WebRequest.Create("HTTPS://secure.fusebill.com/v1/SubscriptionCustomFields/");
//Add Content type
request.ContentType = "application/json";
//Add Api key authorization
request.Headers.Add(HttpRequestHeader.Authorization, "Basic "+apiKey);
//Set request method
request.Method = "PUT";
//Add the json data to request
using (var streamWriter = new StreamWriter(request.GetRequestStream()))
//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}', 'Content-Type' : 'application/json'}
#Pass in a dictionary to the Payload parameter
payload = {'key':'somecustomfield','subscriptionId':{id},'Value':'default value'}
#Pass in your URI, Payload and Headers
r = requests.put('https://secure.fusebill.com/v1/subscriptionCustomFields', data=json.dumps(payload), headers=headers)
  "subscriptionId": 51234,
  "key": "PolicyNumber",
  "Value": "AB12388Sen"
//type mismatch
    "ErrorId": 0,
    "HttpStatusCode": 400,
    "Errors": [
            "Key": "Api Error",
            "Value": "Value must be a number"