Click or drag to resize
dyostem api documentation

ThirdPartySystemGetBlockDataTypes Method

[This is preliminary documentation and is subject to change.]

Return the list of all block data types defined in the system for the connected customer.

Namespace:  Dyostem.Services
Assembly:  Dyostem (in Dyostem.dll) Version: 5.3
Syntax
public BlockDataTypesListResult GetBlockDataTypes(
	string sessionId
)

Parameters

sessionId
Type: SystemString
The SessionId returned by the OpenSession(String, String) command.

Return Value

Type: BlockDataTypesListResult
An instance of BlockDataTypesListResult compound with a Message indicating that the command succeeded or not, and the requested list.
Examples
Request
1POST http://www.dyostem.com/Services/ThirdPartySystem.svc/GetBlockDataTypes HTTP/1.1
2Content-Type: application/json
3Host: www.dyostem.com
4Content-Length: 52
5Expect: 100-continue
6Connection: Keep-Alive
7
8{"sessionId":"d291a5c8-60ab-429a-a167-1a97d15c91b3"}
Response
 1HTTP/1.1 200 OK
 2Cache-Control: private
 3Transfer-Encoding: chunked
 4Content-Type: application/json; charset=utf-8
 5Server: Microsoft-IIS/7.5
 6Set-Cookie: ASP.NET_SessionId=id0np0mg3r3tamhfgozgkm5d; path=/; HttpOnly
 7X-AspNet-Version: 4.0.30319
 8X-Powered-By: ASP.NET
 9Date: Mon, 23 May 2016 14:56:31 GMT
10
113a6f
12{"d":{"__type":"BlockDataTypesListResult:#Dyostem.Services.Data","BlockDataTypes":[{"__type":"BlockDataType:#Dyostem.Services.Data","AvailableValues":null,"Format":"Chaine de caractères","Id":"01df3f72-21d5-4802-a624-2c78dfdb95c0","Name":"Adresse email","Unit":""},{"__type":"BlockDataType:#Dyostem.Services.Data","AvailableValues":[{"__type":"AvailableValue:#Dyostem.Services.Data","Id":"6c895056-4bf2-4889-8e19-0e51fab6a560","Name":"Abondant"},
1314{"__type":"AvailableValue:#Dyostem.Services.Data","Id":"4a5a10fb-3cbc-4275-877f-444f2d911e0e","Name":"Xarello"},{"__type":"AvailableValue:#Dyostem.Services.Data","Id":"3e10b148-1a3f-49c1-9e69-61f49654a916","Name":"Zinfandel"}],"Format":"Choix unique sur liste","Id":"21d926d8-fbfc-4d03-87f0-90e7c0462f6b","Name":"Cépage","Unit":""},{"__type":"BlockDataType:#Dyostem.Services.Data","AvailableValues":null,"Format":"Chaine de caractères","Id":"a8746b22-6080-485f-82ab-eef0735fca14","Name":"Code barre","Unit":""},{"__type":"BlockDataType:#Dyostem.Services.Data","AvailableValues":null,"Format":"Chaine de caractères","Id":"f0cda574-ab7f-467c-8dc8-bd8c13a0dfe5","Name":"Propriétaire","Unit":""},{"__type":"BlockDataType:#Dyostem.Services.Data","AvailableValues":null,"Format":"Numérique","Id":"b6df4e72-c70e-4826-b620-aa4748a68019","Name":"Rendement","Unit":"t\/ha"},{"__type":"BlockDataType:#Dyostem.Services.Data","AvailableValues":null,"Format":"Numérique","Id":"186bb44d-e213-436d-af3e-ab5cbd100d35","Name":"Superficie","Unit":"ha"},{"__type":"BlockDataType:#Dyostem.Services.Data","AvailableValues":[],"Format":"Numérique","Id":"9fdb5eab-9a19-4d4b-8d8b-faed92304f98","Name":"Superficie","Unit":""}],"Message":"OK"}}
150
Formated Json Response
 1{
 2  "d" : {
 3    "__type" : "BlockDataTypesListResult:#Dyostem.Services.Data",
 4    "BlockDataTypes" : [{
 5        "__type" : "BlockDataType:#Dyostem.Services.Data",
 6        "AvailableValues" : null,
 7        "Format" : "Chaine de caractères",
 8        "Id" : "01df3f72-21d5-4802-a624-2c78dfdb95c0",
 9        "Name" : "Adresse email",
10        "Unit" : ""
11    }, {
12        "__type" : "BlockDataType:#Dyostem.Services.Data",
13        "AvailableValues" : [{
14            "__type" : "AvailableValue:#Dyostem.Services.Data",
15            "Id" : "6c895056-4bf2-4889-8e19-0e51fab6a560",
16            "Name" : "Abondant"
17    }, 
18...
19         {
20            "__type" : "AvailableValue:#Dyostem.Services.Data",
21            "Id" : "3e10b148-1a3f-49c1-9e69-61f49654a916",
22            "Name" : "Zinfandel"
23    }
24        ],
25        "Format" : "Choix unique sur liste",
26        "Id" : "21d926d8-fbfc-4d03-87f0-90e7c0462f6b",
27        "Name" : "Cépage",
28        "Unit" : ""
29    }, {
30        "__type" : "BlockDataType:#Dyostem.Services.Data",
31        "AvailableValues" : null,
32        "Format" : "Chaine de caractères",
33        "Id" : "a8746b22-6080-485f-82ab-eef0735fca14",
34        "Name" : "Code barre",
35        "Unit" : ""
36    }, {
37        "__type" : "BlockDataType:#Dyostem.Services.Data",
38        "AvailableValues" : null,
39        "Format" : "Chaine de caractères",
40        "Id" : "f0cda574-ab7f-467c-8dc8-bd8c13a0dfe5",
41        "Name" : "Propriétaire",
42        "Unit" : ""
43    }, {
44        "__type" : "BlockDataType:#Dyostem.Services.Data",
45        "AvailableValues" : null,
46        "Format" : "Numérique",
47        "Id" : "b6df4e72-c70e-4826-b620-aa4748a68019",
48        "Name" : "Rendement",
49        "Unit" : "t\/ha"
50    }, {
51        "__type" : "BlockDataType:#Dyostem.Services.Data",
52        "AvailableValues" : null,
53        "Format" : "Numérique",
54        "Id" : "186bb44d-e213-436d-af3e-ab5cbd100d35",
55        "Name" : "Superficie",
56        "Unit" : "ha"
57    }
58
59    ],
60    "Message" : "OK"
61  }
62}
SOAP 1.1 The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.
Request
 1POST /soap/ThirdPartySystem.asmx HTTP/1.1
 2Host: www.dyostem.com
 3Content-Type: text/xml; charset=utf-8
 4Content-Length: length
 5SOAPAction: "http://www.dyostem.com/soap/ThirdPartySystem/GetBlockDataTypes"
 6
 7<?xml version="1.0" encoding="utf-8"?>
 8<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
 9  <soap:Body>
10    <GetBlockDataTypes xmlns="http://www.dyostem.com/soap/ThirdPartySystem">
11      <sessionId>string</sessionId>
12    </GetBlockDataTypes>
13  </soap:Body>
14</soap:Envelope>
Response
 1HTTP/1.1 200 OK
 2Content-Type: text/xml; charset=utf-8
 3Content-Length: length
 4
 5<?xml version="1.0" encoding="utf-8"?>
 6<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
 7  <soap:Body>
 8    <OpenSessionResponse xmlns="http://www.dyostem.com/soap">
 9      <OpenSessionResult>
10        <Message>string</Message>
11        <SessionId>guid</SessionId>
12      </OpenSessionResult>
13    </OpenSessionResponse>
14  </soap:Body>
15</soap:Envelope>
SOAP 1.2 The following is a sample SOAP 1.2 request and response. The placeholders shown need to be replaced with actual values.
Request
 1POST /soap/ThirdPartySystem.asmx HTTP/1.1
 2Host: www.dyostem.com
 3Content-Type: application/soap+xml; charset=utf-8
 4Content-Length: length
 5
 6<?xml version="1.0" encoding="utf-8"?>
 7<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
 8  <soap12:Body>
 9    <OpenSession xmlns="http://www.dyostem.com/soap">
10      <sLogin>string</sLogin>
11      <sPassword>string</sPassword>
12    </OpenSession>
13  </soap12:Body>
14</soap12:Envelope>
Response
 1HTTP/1.1 200 OK
 2Content-Type: application/soap+xml; charset=utf-8
 3Content-Length: length
 4
 5<?xml version="1.0" encoding="utf-8"?>
 6<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
 7  <soap12:Body>
 8    <OpenSessionResponse xmlns="http://www.dyostem.com/soap">
 9      <OpenSessionResult>
10        <Message>string</Message>
11        <SessionId>guid</SessionId>
12      </OpenSessionResult>
13    </OpenSessionResponse>
14  </soap12:Body>
15</soap12:Envelope>
HTTP POST The following is a sample HTTP POST request and response. The placeholders shown need to be replaced with actual values.
Request
1POST /soap/ThirdPartySystem.asmx/OpenSession HTTP/1.1
2Host: www.dyostem.com
3Content-Type: application/x-www-form-urlencoded
4Content-Length: length
5
6sLogin=string&sPassword=string
Response
1HTTP/1.1 200 OK
2Content-Type: text/xml; charset=utf-8
3Content-Length: length
4
5<?xml version="1.0" encoding="utf-8"?>
6<SessionResult xmlns="http://www.dyostem.com/soap">
7  <Message>string</Message>
8  <SessionId>guid</SessionId>
9</SessionResult>
See Also