POST api/ChoiceList
Get field choice list based on field id or field name
Request Information
URI Parameters
None.
Body Parameters
binder
FieldBinder| Name | Description | Type | Additional information |
|---|---|---|---|
| ProjectId | integer |
None. |
|
| Field |
If Option equals 0, Value should be a field's Id , else Value should be a field's Name. |
ParamValueObject |
None. |
Request Formats
application/json, text/json
Sample:
{
"ProjectId": 1,
"Field": {
"Value": "sample string 1",
"Option": 2
}
}
application/xml, text/xml
Sample:
<FieldBinder xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TechExcel.DTKService.Model.Binding">
<Field>
<Option>2</Option>
<Value>sample string 1</Value>
</Field>
<ProjectId>1</ProjectId>
</FieldBinder>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
Get field choice list based on field id or field name
API_Data_ListOfChoiceObject| Name | Description | Type | Additional information |
|---|---|---|---|
| Success | boolean |
None. |
|
| Error | ErrorInfo |
None. |
|
| Data | Collection of ChoiceObject |
None. |
Response Formats
application/json, text/json
Sample:
{
"Success": true,
"Error": {
"ErrorCode": 1,
"ErrorMessage": "sample string 1"
},
"Data": [
{
"Id": 1,
"Name": "sample string 2",
"IsActive": true
},
{
"Id": 1,
"Name": "sample string 2",
"IsActive": true
}
]
}
application/xml, text/xml
Sample:
<API_Data_ArrayOfChoiceObject xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TechExcel.DTKService.Model.Common">
<Data>
<ChoiceObject>
<Id>1</Id>
<IsActive>true</IsActive>
<Name>sample string 2</Name>
</ChoiceObject>
<ChoiceObject>
<Id>1</Id>
<IsActive>true</IsActive>
<Name>sample string 2</Name>
</ChoiceObject>
</Data>
<Error>
<ErrorCode>1</ErrorCode>
<ErrorMessage>sample string 1</ErrorMessage>
</Error>
<Success>true</Success>
</API_Data_ArrayOfChoiceObject>