Sign in

Welcome.
How can we help?

Freespee API - Getting started

Topic: , Updated:

1. Get access to the API

Create a ticket asking for your API access details. Please also provide us with your IP address(es) for access.

2. Test your credentials

Let's go ahead and use the /miscellaneous/ping resource to verify your partner credentials:

GET /miscellaneous/ping
{
 "ping":"ok"
}

Nice! We have access. If you plan to build some type of “keepalive” or “ping” service towards Freespee, please use this resource.

3. Create a customer

Now we will create your first customer using the API:

POST /customers
name=DailyLoans&custnr=1412
{
 "customers":[{
  "customer_id":"407382",
  "name":"DailyLoans",
  "custnr":"1412",
  "corporateid":"",
  "email":"",
  "uuid":"0097bfcb-9c9c-45ae-b811-2dcc3e799100",
  "dncs_class_name":"",
  "receive_monthly_report":"0",
  "freespee_caller_id":"0"
 }]
}

Not that hard, huh?

4. Create a source

Since we've now created your first customer, let's go ahead and create a source for DailyLoans that we will use for an AdWords campaign on Google:

POST /sources
customer_id=407390&name=AdWords&media=Google.com&phonenr=0890510
{
 "sources":[{
  "source_id":"643971",
  "name":"AdWords",
  "email":null,
  "smsnumber":null,
  "media":"Google.com",
  "customer_id":"407390",
  "phonenr":"+46890510",
  "destnr":"+4612345678",
  "timestamp":"2011-11-14 23:00:00",
  "expire":null,
  "created":"2011-10-15 16:09:31",
  "modified":"2011-10-15 16:09:31",
  "class":"0",
  "status":"active",
  "vm_greeting_id":null,
  "notify_on_missed_call":"0",
  "vm_divert_all":"0",
  "vm_divert_busy":"0",
  "vm_divert_noanswer":"0",
  "alt_numbers":[]
 }]
}

Note that since we did not specify any activation date, this newly created source becomes instantaneously activated (status=active).

Congratulations! You've now learned how to create a customer and assign a source to that customer using the Freespee API.

For developers API Introduction and Examples

For developers API Resources

Was this article helpful?
0 out of 0 found this helpful

Comments


Not the answer to your question?

Powered by Zendesk