Loading...

POST   https://api.3seventy.com/api/v2.1/account/{accountId}/callback

Description

Creates a new callback object.

Path Parameters

accountId integer The account that needs a callback setup. required

Request Properties application/json

CallbackType number The type of callback. required
URL string URL to callback required
Active boolean Used to quickly enable/disable the callback. required
{
    "CallbackTypeId": 1,
    "URL": "http://callbackreceiver.com/api/KeywordResponder/",
    "Active": true
}

C#


using System;
using System.Collections.Generic;
using System.Linq;
using ThreeSeventy.Vector.Client;
using ThreeSeventy.Vector.Client.Models;

public class Program
{

private static void Main(string[] args)
{

const int accountId = 4662;

var context = new T70Context();

var callbackRepo = context.Repository<Callback>(new { AccountId = accountId });

var item = new Callback()
{

Active = true,

AccountId = accountId,

CallbackType = CallbackType.Keyword,

Url = ""

};

callbackRepo.Add(item);

}

}