| POST | /v1/forms/go-send/preview |
|---|
using System;
using System.IO;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using CRM.AgencyPlatform.API.Internal;
namespace CRM.AgencyPlatform.API.Internal
{
public partial class FormGoPosition
{
public virtual string SkillUID { get; set; }
public virtual string Name { get; set; }
public virtual bool Active { get; set; }
public virtual bool Ticked { get; set; }
public virtual int Count { get; set; }
}
public partial class FormGoSendPreviewRequest
{
public virtual Guid FormUID { get; set; }
public virtual string Mode { get; set; }
public virtual List<string> Positions { get; set; } = [];
public virtual List<int> Workers { get; set; } = [];
public virtual bool WithRows { get; set; }
}
public partial class FormGoSendPreviewResponse
{
public virtual List<FormGoPosition> Positions { get; set; } = [];
public virtual List<FormGoSendWorker> Workers { get; set; } = [];
public virtual int Send { get; set; }
public virtual int Skipped { get; set; }
public virtual string Consequence { get; set; }
public virtual string SendLabel { get; set; }
public virtual string Refusal { get; set; }
public virtual string SendOff { get; set; }
public virtual int Max { get; set; }
public virtual ResponseStatus ResponseStatus { get; set; }
}
public partial class FormGoSendWorker
{
public virtual int Id { get; set; }
public virtual string Name { get; set; }
public virtual string Position { get; set; }
public virtual bool Submitted { get; set; }
}
}
C# FormGoSendPreviewRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /v1/forms/go-send/preview HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
FormUID: 00000000000000000000000000000000,
Mode: String,
Positions:
[
String
],
Workers:
[
0
],
WithRows: False
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
Positions:
[
{
SkillUID: String,
Name: String,
Active: False,
Ticked: False,
Count: 0
}
],
Workers:
[
{
Id: 0,
Name: String,
Position: String,
Submitted: False
}
],
Send: 0,
Skipped: 0,
Consequence: String,
SendLabel: String,
Refusal: String,
SendOff: String,
Max: 0,
ResponseStatus:
{
ErrorCode: String,
Message: String,
StackTrace: String,
Errors:
[
{
ErrorCode: String,
FieldName: String,
Message: String,
Meta:
{
String: String
}
}
],
Meta:
{
String: String
}
}
}