To post or update data in ACTIVENet using a POST or PUT API (except the PostForgotPassword and PostForgotLoginName APIs), please apply for a write-access API key by contacting the ACTIVENet support team and provide the IP address(es) or subnet(s). Your system needs to:
Call the API using the HTTP POST method with the required request parameters.
Parse the JSON-formatted response.
To call the PostForgotPassword or PostForgotLoginName API, refer here.
Note that if you have enabled enhanced-security ACTIVENet System APIs, to make API requests using both the API key and a digital signature, refer here.
To prepare the request URL for an API call, refer to the Preparing your request URL section on the Retrieving data from ACTIVE Net page.
Note that for a POST or PUT API request, the service name is different, a separate write-access API key is required, and request parameters are included in the body of the request.
For example:
§ The service name for POST and PUT APIs is wr.
§ Your Live site organization ID is orgtest and your Trainer site organization id orgtesttrainer.
§ You are using version 1 (v1) of the API
§ Refer to the List of System APIs to view specifications for the required API.
§ Your Live site API key is specified as api_key=1234567890ab3xnteudxsavw
§ Your Trainer site API key is specified as api_key=0987654321ab3xnteudxsavw
The request URL for the Live site is:
https://api.amp.active.com/wr/orgtest/api/v1/customers&api_key=1234567890ab3xnteudxsavw
The request URL for the Trainer site is:
https://api.amp.active.com/wr/orgtesttrainer/api/v1/customers&api_key=1234567890ab3xnteudxsavw
Refer to the API specifications page to view a list of supported request parameters and see the example for how to include them in the request.
Unlike other APIs, the request parameters for a POST or PUT API are included in the body of the request.
PUT /customers HTTP/1.1
Content-Type: application/json
Accept: application/json
Content-Length: 1641
Host: api.amp.active.com:8080
{
"body": [
{
"customer_id": 1,
"first_name": "xxx1",
"last_name": "ddd",
"email": "yyy@gmail.com",
"birth_date": "2005-01-11",
"middle_name": "1212",
"SSN": "123456",
"mailing_address1": "mailing_address1",
"mailing_address2": "mailing_address2",
"mailing_city": "LA",
"mailing_state_or_province_id": 44,
"mailing_zip_code": "12345",
"mailing_name": "mailing_name",
"residential_address1": "residential_address1",
"residential_address2": "residential_address2",
"residential_city": "residential_city",
"residential_state_or_province_id": 44,
"residential_zip_code": "12345",
"additional_email": "xxx@gmail.com",
"gender_id": 1,
"resident": true,
"head_of_household": true,
"no_mail": true,
"no_postal_mail": true,
"customer_notes": "this is notes",
"customer_medical_alert": "this is medical alert",
"customer_general_alert": "this is general alert",
"families": [
{
"family_id": 2
}
],
"preferred_language_id": 2,
"h_area": "223",
"h_phone": "1234567",
"h_ext": "1233333",
"w_area": "223",
"w_phone": "1234567",
"w_ext": "1233333",
"c_area": "223",
"c_phone": "1234567",
"c_ext": "1233333"
}
]
}
Once you make a request to the API with the required parameters, you will receive an API response. A successful request returns the HTTP 200 OK status code and a JSON-formatted response body.
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 468
{
"headers" : {
"response_code" : "0000",
"response_message" : "Successful"
},
"body" : [ {
"successfully_updated_customer" : [ {
"customer_id" : 1,
"first_name" : "first_name",
"last_name" : "last_name",
"email" : "email"
} ],
"failed_updated_customer" : [ {
"first_name" : "first_name",
"last_name" : "last_name",
"email" : "email",
"failed_error" : "error"
} ]
} ]
}
For POST or PUT request APIs, in the HTTP body, the ‘Successful’ response_message indicates that the provided information has been successfully posted and the ‘body’ section may include additional response fields.
For more information on response fields, refer to the Response Body section for each individual API.
For more information about error handling, refer to Error handling.
To post data in ACTIVENet using the PostForgotPassword or PostForgotLoginName APIs, your system needs to:
Call the API using the HTTP POST method with the required request parameters.
Parse the JSON-formatted response.
This chapter includes the following sections:
Note that if you have enabled enhanced-security ACTIVENet System APIs, to make API requests using both the API key and a digital signature, refer here.
To prepare the request URL for an API call, refer to the Preparing your request URL section on the Retrieving data from ACTIVE Net page.
For example:
§ If your service name is anet-systemapi.
§ Your Live site organization ID is orgtest and your Trainer site organization id orgtesttrainer.
§ You are using version 1 (v1) of the API
§ Refer to the List of System APIs to view specifications for the required API.
§ Your Live site API key is specified as api_key=1234567890xn3xnteudxsavw
§ Your Trainer site API key is specified as api_key=0987654321xn3xnteudxsavw
The request URL for the Live site is:
https://api.amp.active.com/anet-systemapi/orgtest/api/v1/forgotloginname?email=test@test.com&api_key=1234567890xn3xnteudxsavw
The request URL for the Trainer site is:
https://api.amp.active.com/anet-systemapi/orgtesttrainer/api/v1/forgotloginname?email=test@test.com&api_key=1234567890xn3xnteudxsavw
Refer to the Request parameters section on the Retrieving data from ACTIVE Net page on how to include multiple request parameters in the URL.
Once you make a request to the API with the required parameters, you will receive an API response. A successful request returns the HTTP 200 OK status code and a JSON-formatted response body.
{
"headers" : {
"response_code" : "0000",
"response_message" : "Successful"
},
"body" : [ ]
}
For POST request APIs, in the HTTP body, the ‘Successful’ response_message indicates that the provided information has been successfully posted and the ‘body’ section may include additional response fields.
For more information on response fields, refer to the Response Body section for each individual API.
For more information about error handling, refer to Error handling.
Retrieving data from ACTIVE Net