GET | /integrations |
---|
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';
enum SortOrders
{
Ascend,
Descend,
}
abstract class ListRequest<T> implements IGet
{
/**
* The page of data to retrieve
*/
// @ApiMember(Description="The page of data to retrieve")
int? page;
/**
* If you want all objects to be returned. This should be used with care
*/
// @ApiMember(Description="If you want all objects to be returned. This should be used with care")
bool? all;
/**
* The number per page to retrieve
*/
// @ApiMember(Description="The number per page to retrieve")
int? countPerPage;
/**
* Specific IDs
*/
// @ApiMember(Description="Specific IDs")
List<String>? specificIds;
/**
* Specify a sort field
*/
// @ApiMember(Description="Specify a sort field")
String? sortField;
/**
* Specify a sort order
*/
// @ApiMember(Description="Specify a sort order")
SortOrders? sortOrder;
/**
* Disables total / page counts - improves performance. Returns only data. If there is no more data, Items will be empty array
*/
// @ApiMember(Description="Disables total / page counts - improves performance. Returns only data. If there is no more data, Items will be empty array")
bool? simplifiedPaging;
ListRequest({this.page,this.all,this.countPerPage,this.specificIds,this.sortField,this.sortOrder,this.simplifiedPaging});
ListRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
page = json['page'];
all = json['all'];
countPerPage = json['countPerPage'];
specificIds = JsonConverters.fromJson(json['specificIds'],'List<String>',context!);
sortField = json['sortField'];
sortOrder = JsonConverters.fromJson(json['sortOrder'],'SortOrders',context!);
simplifiedPaging = json['simplifiedPaging'];
return this;
}
Map<String, dynamic> toJson() => {
'page': page,
'all': all,
'countPerPage': countPerPage,
'specificIds': JsonConverters.toJson(specificIds,'List<String>',context!),
'sortField': sortField,
'sortOrder': JsonConverters.toJson(sortOrder,'SortOrders',context!),
'simplifiedPaging': simplifiedPaging
};
getTypeName() => "ListRequest<$T>";
TypeContext? context = _ctx;
}
abstract class EntityInfo
{
/**
* The ID of the object
*/
// @ApiMember(Description="The ID of the object")
String? id;
/**
* The date the object was created
*/
// @ApiMember(Description="The date the object was created")
String? dateCreated;
/**
* The date the object was last modified
*/
// @ApiMember(Description="The date the object was last modified")
String? dateLastModified;
/**
* The user that created this object
*/
// @ApiMember(Description="The user that created this object")
String? createdBy;
/**
* The user that last modified this object
*/
// @ApiMember(Description="The user that last modified this object")
String? lastModifiedBy;
EntityInfo({this.id,this.dateCreated,this.dateLastModified,this.createdBy,this.lastModifiedBy});
EntityInfo.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
dateCreated = json['dateCreated'];
dateLastModified = json['dateLastModified'];
createdBy = json['createdBy'];
lastModifiedBy = json['lastModifiedBy'];
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'dateCreated': dateCreated,
'dateLastModified': dateLastModified,
'createdBy': createdBy,
'lastModifiedBy': lastModifiedBy
};
getTypeName() => "EntityInfo";
TypeContext? context = _ctx;
}
class CustomerBreadcrumb implements IConvertible
{
String? id;
String? name;
CustomerBreadcrumb({this.id,this.name});
CustomerBreadcrumb.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
name = json['name'];
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'name': name
};
getTypeName() => "CustomerBreadcrumb";
TypeContext? context = _ctx;
}
enum IntegrationTypes
{
HostedSuite,
OfficeRnd,
Zoho,
}
enum IntegrationStatuses
{
NotConfigured,
Error,
OK,
}
enum ValueTypes
{
NotSpecified,
String,
Boolean,
Number,
List,
Struct,
Transition,
Custom,
Date,
AudioFile,
TimeZoneId,
PhoneNumber,
User,
Endpoint,
Time,
File,
FaxNumber,
EmailAccount,
Customer,
Flow,
Team,
FlowReference,
Integration,
Assistant,
}
enum UIHints
{
None,
LargeText,
InlineForm,
Password,
InlineStruct,
}
class Struct extends Map<String,Value?> implements IConvertible
{
Struct();
Struct.fromJson(Map<String, dynamic> json) : super.fromJson(json);
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
return this;
}
Map<String, dynamic> toJson() => super.toJson();
getTypeName() => "Struct";
TypeContext? context = _ctx;
}
class Value implements IConvertible
{
bool? boolValue;
String? stringValue;
double? numberValue;
List<Struct>? listValue;
Struct? structValue;
Value({this.boolValue,this.stringValue,this.numberValue,this.listValue,this.structValue});
Value.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
boolValue = json['boolValue'];
stringValue = json['stringValue'];
numberValue = JsonConverters.toDouble(json['numberValue']);
listValue = JsonConverters.fromJson(json['listValue'],'List<Struct>',context!);
structValue = JsonConverters.fromJson(json['structValue'],'Struct',context!);
return this;
}
Map<String, dynamic> toJson() => {
'boolValue': boolValue,
'stringValue': stringValue,
'numberValue': numberValue,
'listValue': JsonConverters.toJson(listValue,'List<Struct>',context!),
'structValue': JsonConverters.toJson(structValue,'Struct',context!)
};
getTypeName() => "Value";
TypeContext? context = _ctx;
}
enum DataFieldUniqueness
{
NotUnique,
Unique,
UniqueToCustomer,
}
enum UserDataFieldModes
{
Hidden,
ReadOnly,
ReadWrite,
}
class DataField implements IConvertible
{
String? id;
String? name;
ValueTypes? type;
UIHints? uiHint;
String? uiTab;
bool? isAsync;
bool? disableBinding;
DataType? structType;
DataType? listType;
String? description;
List<String>? possibleValues;
bool? isOutput;
String? customFieldValuesUrl;
Value? defaultValue;
String? transitionNameFormat;
DataFieldUniqueness? uniqueness;
bool? voiceOnly;
String? conditionalVisibilityField;
String? conditionalVisibilityValue;
bool? noEvalTemplate;
UserDataFieldModes? userMode;
bool? anyValueType;
DataField({this.id,this.name,this.type,this.uiHint,this.uiTab,this.isAsync,this.disableBinding,this.structType,this.listType,this.description,this.possibleValues,this.isOutput,this.customFieldValuesUrl,this.defaultValue,this.transitionNameFormat,this.uniqueness,this.voiceOnly,this.conditionalVisibilityField,this.conditionalVisibilityValue,this.noEvalTemplate,this.userMode,this.anyValueType});
DataField.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
name = json['name'];
type = JsonConverters.fromJson(json['type'],'ValueTypes',context!);
uiHint = JsonConverters.fromJson(json['uiHint'],'UIHints',context!);
uiTab = json['uiTab'];
isAsync = json['isAsync'];
disableBinding = json['disableBinding'];
structType = JsonConverters.fromJson(json['structType'],'DataType',context!);
listType = JsonConverters.fromJson(json['listType'],'DataType',context!);
description = json['description'];
possibleValues = JsonConverters.fromJson(json['possibleValues'],'List<String>',context!);
isOutput = json['isOutput'];
customFieldValuesUrl = json['customFieldValuesUrl'];
defaultValue = JsonConverters.fromJson(json['defaultValue'],'Value',context!);
transitionNameFormat = json['transitionNameFormat'];
uniqueness = JsonConverters.fromJson(json['uniqueness'],'DataFieldUniqueness',context!);
voiceOnly = json['voiceOnly'];
conditionalVisibilityField = json['conditionalVisibilityField'];
conditionalVisibilityValue = json['conditionalVisibilityValue'];
noEvalTemplate = json['noEvalTemplate'];
userMode = JsonConverters.fromJson(json['userMode'],'UserDataFieldModes',context!);
anyValueType = json['anyValueType'];
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'name': name,
'type': JsonConverters.toJson(type,'ValueTypes',context!),
'uiHint': JsonConverters.toJson(uiHint,'UIHints',context!),
'uiTab': uiTab,
'isAsync': isAsync,
'disableBinding': disableBinding,
'structType': JsonConverters.toJson(structType,'DataType',context!),
'listType': JsonConverters.toJson(listType,'DataType',context!),
'description': description,
'possibleValues': JsonConverters.toJson(possibleValues,'List<String>',context!),
'isOutput': isOutput,
'customFieldValuesUrl': customFieldValuesUrl,
'defaultValue': JsonConverters.toJson(defaultValue,'Value',context!),
'transitionNameFormat': transitionNameFormat,
'uniqueness': JsonConverters.toJson(uniqueness,'DataFieldUniqueness',context!),
'voiceOnly': voiceOnly,
'conditionalVisibilityField': conditionalVisibilityField,
'conditionalVisibilityValue': conditionalVisibilityValue,
'noEvalTemplate': noEvalTemplate,
'userMode': JsonConverters.toJson(userMode,'UserDataFieldModes',context!),
'anyValueType': anyValueType
};
getTypeName() => "DataField";
TypeContext? context = _ctx;
}
class DataType implements IConvertible
{
String? typeName;
List<DataField>? fields;
DataType({this.typeName,this.fields});
DataType.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
typeName = json['typeName'];
fields = JsonConverters.fromJson(json['fields'],'List<DataField>',context!);
return this;
}
Map<String, dynamic> toJson() => {
'typeName': typeName,
'fields': JsonConverters.toJson(fields,'List<DataField>',context!)
};
getTypeName() => "DataType";
TypeContext? context = _ctx;
}
enum IntegrationFeatures
{
CrmSync,
OAuth2,
}
class IntegrationInfo extends EntityInfo implements IConvertible
{
/**
* The ID of the account associated with this integration
*/
// @ApiMember(Description="The ID of the account associated with this integration")
String? accountId;
/**
* The ID of the customer this integration is associated with
*/
// @ApiMember(Description="The ID of the customer this integration is associated with")
String? customerId;
/**
* The name of the customer this integration is associated with
*/
// @ApiMember(Description="The name of the customer this integration is associated with")
String? customerName;
/**
* The date the integration was sync'd last
*/
// @ApiMember(Description="The date the integration was sync'd last")
String? dateLastSync;
/**
* The breadcrumb to the customer for this integration
*/
// @ApiMember(Description="The breadcrumb to the customer for this integration")
List<CustomerBreadcrumb>? customerBreadcrumb;
/**
* The name of the integration (e.g. HostedSuite Dallas)
*/
// @ApiMember(Description="The name of the integration (e.g. HostedSuite Dallas)")
String? name;
/**
* Automatically create new customers / users when sync'ing with CRM?
*/
// @ApiMember(Description="Automatically create new customers / users when sync'ing with CRM?")
bool? automaticallyCreateCustomers;
/**
* The type of integration
*/
// @ApiMember(Description="The type of integration")
IntegrationTypes? type;
/**
* The status of the integration
*/
// @ApiMember(Description="The status of the integration")
IntegrationStatuses? status;
/**
* The status of the integration
*/
// @ApiMember(Description="The status of the integration")
String? statusMessage;
/**
* The settings type for this integration
*/
// @ApiMember(Description="The settings type for this integration")
DataType? settingsDataType;
/**
* The settings for this integration
*/
// @ApiMember(Description="The settings for this integration")
Struct? settings;
/**
* The features supported by this integration
*/
// @ApiMember(Description="The features supported by this integration")
List<IntegrationFeatures>? features;
/**
* Is this integration authorized (OAuth)?
*/
// @ApiMember(Description="Is this integration authorized (OAuth)?")
bool? isAuthorized;
IntegrationInfo({this.accountId,this.customerId,this.customerName,this.dateLastSync,this.customerBreadcrumb,this.name,this.automaticallyCreateCustomers,this.type,this.status,this.statusMessage,this.settingsDataType,this.settings,this.features,this.isAuthorized});
IntegrationInfo.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
accountId = json['accountId'];
customerId = json['customerId'];
customerName = json['customerName'];
dateLastSync = json['dateLastSync'];
customerBreadcrumb = JsonConverters.fromJson(json['customerBreadcrumb'],'List<CustomerBreadcrumb>',context!);
name = json['name'];
automaticallyCreateCustomers = json['automaticallyCreateCustomers'];
type = JsonConverters.fromJson(json['type'],'IntegrationTypes',context!);
status = JsonConverters.fromJson(json['status'],'IntegrationStatuses',context!);
statusMessage = json['statusMessage'];
settingsDataType = JsonConverters.fromJson(json['settingsDataType'],'DataType',context!);
settings = JsonConverters.fromJson(json['settings'],'Struct',context!);
features = JsonConverters.fromJson(json['features'],'List<IntegrationFeatures>',context!);
isAuthorized = json['isAuthorized'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'accountId': accountId,
'customerId': customerId,
'customerName': customerName,
'dateLastSync': dateLastSync,
'customerBreadcrumb': JsonConverters.toJson(customerBreadcrumb,'List<CustomerBreadcrumb>',context!),
'name': name,
'automaticallyCreateCustomers': automaticallyCreateCustomers,
'type': JsonConverters.toJson(type,'IntegrationTypes',context!),
'status': JsonConverters.toJson(status,'IntegrationStatuses',context!),
'statusMessage': statusMessage,
'settingsDataType': JsonConverters.toJson(settingsDataType,'DataType',context!),
'settings': JsonConverters.toJson(settings,'Struct',context!),
'features': JsonConverters.toJson(features,'List<IntegrationFeatures>',context!),
'isAuthorized': isAuthorized
});
getTypeName() => "IntegrationInfo";
TypeContext? context = _ctx;
}
/**
* Retrieve integrations
*/
// @Api(Description="Retrieve integrations")
class ListIntegrations extends ListRequest<IntegrationInfo> implements IConvertible
{
/**
* Filter by accounts
*/
// @ApiMember(Description="Filter by accounts")
List<String>? accountIds;
/**
* Filter by name
*/
// @ApiMember(Description="Filter by name")
String? nameFilter;
/**
* The IDs of the parent customers you want to filter by
*/
// @ApiMember(Description="The IDs of the parent customers you want to filter by")
List<String>? customerIds;
/**
* If you want a shall customer integration filter (e.g. no deep children)
*/
// @ApiMember(Description="If you want a shall customer integration filter (e.g. no deep children)")
bool? shallowParent;
ListIntegrations({this.accountIds,this.nameFilter,this.customerIds,this.shallowParent});
ListIntegrations.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
accountIds = JsonConverters.fromJson(json['accountIds'],'List<String>',context!);
nameFilter = json['nameFilter'];
customerIds = JsonConverters.fromJson(json['customerIds'],'List<String>',context!);
shallowParent = json['shallowParent'];
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'accountIds': JsonConverters.toJson(accountIds,'List<String>',context!),
'nameFilter': nameFilter,
'customerIds': JsonConverters.toJson(customerIds,'List<String>',context!),
'shallowParent': shallowParent
});
getTypeName() => "ListIntegrations";
TypeContext? context = _ctx;
}
class BillingItem implements IConvertible
{
double? baseCost;
double? rawUnitMultiplier;
double? unitCost;
int? allowance;
BillingItem({this.baseCost,this.rawUnitMultiplier,this.unitCost,this.allowance});
BillingItem.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
baseCost = JsonConverters.toDouble(json['baseCost']);
rawUnitMultiplier = JsonConverters.toDouble(json['rawUnitMultiplier']);
unitCost = JsonConverters.toDouble(json['unitCost']);
allowance = json['allowance'];
return this;
}
Map<String, dynamic> toJson() => {
'baseCost': baseCost,
'rawUnitMultiplier': rawUnitMultiplier,
'unitCost': unitCost,
'allowance': allowance
};
getTypeName() => "BillingItem";
TypeContext? context = _ctx;
}
class BillingSettings implements IConvertible
{
BillingItem? base;
BillingItem? localNumbers;
BillingItem? tollFreeNumbers;
BillingItem? inboundVoiceCalls;
BillingItem? outboundVoiceCalls;
BillingItem? inboundFaxes;
BillingItem? outboundFaxes;
BillingItem? inboundSmsMessages;
BillingItem? outboundSmsMessages;
BillingItem? aiInsights;
BillingItem? aiLiveMinutes;
BillingSettings({this.base,this.localNumbers,this.tollFreeNumbers,this.inboundVoiceCalls,this.outboundVoiceCalls,this.inboundFaxes,this.outboundFaxes,this.inboundSmsMessages,this.outboundSmsMessages,this.aiInsights,this.aiLiveMinutes});
BillingSettings.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
base = JsonConverters.fromJson(json['base'],'BillingItem',context!);
localNumbers = JsonConverters.fromJson(json['localNumbers'],'BillingItem',context!);
tollFreeNumbers = JsonConverters.fromJson(json['tollFreeNumbers'],'BillingItem',context!);
inboundVoiceCalls = JsonConverters.fromJson(json['inboundVoiceCalls'],'BillingItem',context!);
outboundVoiceCalls = JsonConverters.fromJson(json['outboundVoiceCalls'],'BillingItem',context!);
inboundFaxes = JsonConverters.fromJson(json['inboundFaxes'],'BillingItem',context!);
outboundFaxes = JsonConverters.fromJson(json['outboundFaxes'],'BillingItem',context!);
inboundSmsMessages = JsonConverters.fromJson(json['inboundSmsMessages'],'BillingItem',context!);
outboundSmsMessages = JsonConverters.fromJson(json['outboundSmsMessages'],'BillingItem',context!);
aiInsights = JsonConverters.fromJson(json['aiInsights'],'BillingItem',context!);
aiLiveMinutes = JsonConverters.fromJson(json['aiLiveMinutes'],'BillingItem',context!);
return this;
}
Map<String, dynamic> toJson() => {
'base': JsonConverters.toJson(base,'BillingItem',context!),
'localNumbers': JsonConverters.toJson(localNumbers,'BillingItem',context!),
'tollFreeNumbers': JsonConverters.toJson(tollFreeNumbers,'BillingItem',context!),
'inboundVoiceCalls': JsonConverters.toJson(inboundVoiceCalls,'BillingItem',context!),
'outboundVoiceCalls': JsonConverters.toJson(outboundVoiceCalls,'BillingItem',context!),
'inboundFaxes': JsonConverters.toJson(inboundFaxes,'BillingItem',context!),
'outboundFaxes': JsonConverters.toJson(outboundFaxes,'BillingItem',context!),
'inboundSmsMessages': JsonConverters.toJson(inboundSmsMessages,'BillingItem',context!),
'outboundSmsMessages': JsonConverters.toJson(outboundSmsMessages,'BillingItem',context!),
'aiInsights': JsonConverters.toJson(aiInsights,'BillingItem',context!),
'aiLiveMinutes': JsonConverters.toJson(aiLiveMinutes,'BillingItem',context!)
};
getTypeName() => "BillingSettings";
TypeContext? context = _ctx;
}
class AccountInfo extends EntityInfo implements IConvertible
{
/**
* The name of this account
*/
// @ApiMember(Description="The name of this account")
String? name;
/**
* The ID of this account's parent
*/
// @ApiMember(Description="The ID of this account's parent")
String? parentAccountId;
/**
* The twilio account SID
*/
// @ApiMember(Description="The twilio account SID")
String? twilioAccountSid;
/**
* The ancestors of this account. Useful for breadcrumbs
*/
// @ApiMember(Description="The ancestors of this account. Useful for breadcrumbs")
List<String>? ancestorIds;
/**
* The max number of phone numbers this account can have
*/
// @ApiMember(Description="The max number of phone numbers this account can have")
int? maxPhoneNumbers;
/**
* This account is BYOA
*/
// @ApiMember(Description="This account is BYOA")
bool? isBYOA;
/**
* TrustHub Profile Sid
*/
// @ApiMember(Description="TrustHub Profile Sid")
String? trustHubProfileSid;
/**
* The ID of the logo file
*/
// @ApiMember(Description="The ID of the logo file")
String? logoId;
/**
* The URI of the logo file
*/
// @ApiMember(Description="The URI of the logo file")
String? logoUri;
/**
* The billing settings for this account
*/
// @ApiMember(Description="The billing settings for this account")
BillingSettings? billingSettings;
AccountInfo({this.name,this.parentAccountId,this.twilioAccountSid,this.ancestorIds,this.maxPhoneNumbers,this.isBYOA,this.trustHubProfileSid,this.logoId,this.logoUri,this.billingSettings});
AccountInfo.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
name = json['name'];
parentAccountId = json['parentAccountId'];
twilioAccountSid = json['twilioAccountSid'];
ancestorIds = JsonConverters.fromJson(json['ancestorIds'],'List<String>',context!);
maxPhoneNumbers = json['maxPhoneNumbers'];
isBYOA = json['isBYOA'];
trustHubProfileSid = json['trustHubProfileSid'];
logoId = json['logoId'];
logoUri = json['logoUri'];
billingSettings = JsonConverters.fromJson(json['billingSettings'],'BillingSettings',context!);
return this;
}
Map<String, dynamic> toJson() => super.toJson()..addAll({
'name': name,
'parentAccountId': parentAccountId,
'twilioAccountSid': twilioAccountSid,
'ancestorIds': JsonConverters.toJson(ancestorIds,'List<String>',context!),
'maxPhoneNumbers': maxPhoneNumbers,
'isBYOA': isBYOA,
'trustHubProfileSid': trustHubProfileSid,
'logoId': logoId,
'logoUri': logoUri,
'billingSettings': JsonConverters.toJson(billingSettings,'BillingSettings',context!)
});
getTypeName() => "AccountInfo";
TypeContext? context = _ctx;
}
class ListResponse<T> implements IConvertible
{
/**
* The items
*/
// @ApiMember(Description="The items")
List<AccountInfo>? items;
/**
* The total number of items
*/
// @ApiMember(Description="The total number of items")
int? totalCount;
/**
* The total number of pages
*/
// @ApiMember(Description="The total number of pages")
int? totalPages;
/**
* Are there more pages of items? Used with simplified paging
*/
// @ApiMember(Description="Are there more pages of items? Used with simplified paging")
bool? hasMorePages;
ListResponse({this.items,this.totalCount,this.totalPages,this.hasMorePages});
ListResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
items = JsonConverters.fromJson(json['items'],'List<AccountInfo>',context!);
totalCount = json['totalCount'];
totalPages = json['totalPages'];
hasMorePages = json['hasMorePages'];
return this;
}
Map<String, dynamic> toJson() => {
'items': JsonConverters.toJson(items,'List<AccountInfo>',context!),
'totalCount': totalCount,
'totalPages': totalPages,
'hasMorePages': hasMorePages
};
getTypeName() => "ListResponse<$T>";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'team.evovoice.io', types: <String, TypeInfo> {
'SortOrders': TypeInfo(TypeOf.Enum, enumValues:SortOrders.values),
'ListRequest<T>': TypeInfo(TypeOf.GenericDef,create:() => ListRequest()),
'EntityInfo': TypeInfo(TypeOf.AbstractClass),
'CustomerBreadcrumb': TypeInfo(TypeOf.Class, create:() => CustomerBreadcrumb()),
'IntegrationTypes': TypeInfo(TypeOf.Enum, enumValues:IntegrationTypes.values),
'IntegrationStatuses': TypeInfo(TypeOf.Enum, enumValues:IntegrationStatuses.values),
'ValueTypes': TypeInfo(TypeOf.Enum, enumValues:ValueTypes.values),
'UIHints': TypeInfo(TypeOf.Enum, enumValues:UIHints.values),
'Struct': TypeInfo(TypeOf.Class, create:() => Struct()),
'Value': TypeInfo(TypeOf.Class, create:() => Value()),
'List<Struct>': TypeInfo(TypeOf.Class, create:() => <Struct>[]),
'DataFieldUniqueness': TypeInfo(TypeOf.Enum, enumValues:DataFieldUniqueness.values),
'UserDataFieldModes': TypeInfo(TypeOf.Enum, enumValues:UserDataFieldModes.values),
'DataField': TypeInfo(TypeOf.Class, create:() => DataField()),
'DataType': TypeInfo(TypeOf.Class, create:() => DataType()),
'List<DataField>': TypeInfo(TypeOf.Class, create:() => <DataField>[]),
'IntegrationFeatures': TypeInfo(TypeOf.Enum, enumValues:IntegrationFeatures.values),
'IntegrationInfo': TypeInfo(TypeOf.Class, create:() => IntegrationInfo()),
'List<CustomerBreadcrumb>': TypeInfo(TypeOf.Class, create:() => <CustomerBreadcrumb>[]),
'List<IntegrationFeatures>': TypeInfo(TypeOf.Class, create:() => <IntegrationFeatures>[]),
'ListIntegrations': TypeInfo(TypeOf.Class, create:() => ListIntegrations()),
'BillingItem': TypeInfo(TypeOf.Class, create:() => BillingItem()),
'BillingSettings': TypeInfo(TypeOf.Class, create:() => BillingSettings()),
'AccountInfo': TypeInfo(TypeOf.Class, create:() => AccountInfo()),
'ListResponse<T>': TypeInfo(TypeOf.Class, create:() => ListResponse<T>()),
'List<AccountInfo>': TypeInfo(TypeOf.Class, create:() => <AccountInfo>[]),
});
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /integrations HTTP/1.1 Host: team.evovoice.io Accept: text/csv
HTTP/1.1 200 OK Content-Type: text/csv Content-Length: length {"items":[{"accountId":"String","customerId":"String","customerName":"String","dateLastSync":"String","customerBreadcrumb":[{"id":"String","name":"String"}],"name":"String","automaticallyCreateCustomers":false,"type":"HostedSuite","status":"NotConfigured","statusMessage":"String","features":["CrmSync"],"isAuthorized":false,"id":"String","dateCreated":"String","dateLastModified":"String","createdBy":"String","lastModifiedBy":"String"}],"totalCount":0,"totalPages":0,"hasMorePages":false}