POST api/Object?model={model}

Performs a search in a table for the specified ids/Führt eine Suche für die übergebenen IDs aus

Request Information

Parameters

NameDescriptionAdditional information
model
The model name of the table/Modellname der Tabelle

Define this parameter in the request URI.

getParams
Contains the ids and the fields of the records and the authentication token. Leave fields empty to return all fields.
            Beinhaltet den Anmeldetoken und die IDs und gewünschten Felder der Datensätze. Lassen Sie die Felder leer, um alle Daten zurückzugeben.

Define this parameter in the request body.

Request body formats

application/json, text/json

Sample:
{
  "AuthToken": "your authentication token",
  "IDs": [
    2,
    5,
    8
  ],
  "Fields": [
    "name",
    "street",
    "city"
  ]
}

application/xml, text/xml

Sample:
<GetRecordsRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/openErpRestApi.Models">
  <AuthToken>your authentication token</AuthToken>
  <Fields xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:anyType xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:string">name</d2p1:anyType>
    <d2p1:anyType xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:string">street</d2p1:anyType>
    <d2p1:anyType xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:string">city</d2p1:anyType>
  </Fields>
  <IDs xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:anyType xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:int">2</d2p1:anyType>
    <d2p1:anyType xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:int">5</d2p1:anyType>
    <d2p1:anyType xmlns:d3p1="http://www.w3.org/2001/XMLSchema" i:type="d3p1:int">8</d2p1:anyType>
  </IDs>
</GetRecordsRequest>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Response body formats

application/json, text/json

Sample:
[
  {
    "city": "city1",
    "street": "street1",
    "name": "name1"
  },
  {
    "city": "city2",
    "street": "street2",
    "name": "name2"
  }
]

application/xml, text/xml

Sample:
<ArrayOfArrayOfKeyValueOfanyTypeanyType xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
  <ArrayOfKeyValueOfanyTypeanyType>
    <KeyValueOfanyTypeanyType>
      <Key xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">name</Key>
      <Value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">name1</Value>
    </KeyValueOfanyTypeanyType>
    <KeyValueOfanyTypeanyType>
      <Key xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">street</Key>
      <Value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">street1</Value>
    </KeyValueOfanyTypeanyType>
    <KeyValueOfanyTypeanyType>
      <Key xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">city</Key>
      <Value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">city1</Value>
    </KeyValueOfanyTypeanyType>
  </ArrayOfKeyValueOfanyTypeanyType>
  <ArrayOfKeyValueOfanyTypeanyType>
    <KeyValueOfanyTypeanyType>
      <Key xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">name</Key>
      <Value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">name2</Value>
    </KeyValueOfanyTypeanyType>
    <KeyValueOfanyTypeanyType>
      <Key xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">street</Key>
      <Value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">street2</Value>
    </KeyValueOfanyTypeanyType>
    <KeyValueOfanyTypeanyType>
      <Key xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">city</Key>
      <Value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string">city2</Value>
    </KeyValueOfanyTypeanyType>
  </ArrayOfKeyValueOfanyTypeanyType>
</ArrayOfArrayOfKeyValueOfanyTypeanyType>