POST api/contractapi/add?siteId={siteId}

Request Information

URI Parameters

NameDescriptionTypeAdditional information
siteId

globally unique identifier

None.

Body Parameters

ContractViewModel
NameDescriptionTypeAdditional information
selected_nameplate_id

globally unique identifier

None.

selected_sticker_id

globally unique identifier

None.

washing_processes

Collection of WashingProcessViewModel

None.

active

boolean

Required

certificate_type_id

globally unique identifier

Required

code

integer

None.

delay_between_scans

integer

None.

id

globally unique identifier

None.

internal_reference

string

String length: inclusive between 0 and 50

item_wash_max

integer

None.

language_code

string

Required

String length: inclusive between 0 and 10

name

string

Required

String length: inclusive between 0 and 100

packaging_type_id

globally unique identifier

Required

packing_type_id

globally unique identifier

Required

particles_control

boolean

Required

peremption_month

integer

None.

peremption_print_cleanroom

boolean

Required

peremption_print_date

boolean

Required

peremption_print_expedition

boolean

Required

permanent_management

boolean

Required

pool_id

globally unique identifier

None.

remark

string

None.

site_customer_id

globally unique identifier

Required

sorting_type_id

globally unique identifier

Required

type

string

Required

String length: inclusive between 0 and 1

Request Formats

application/json, text/json

Sample:
{
  "selected_nameplate_id": "cba9d59b-7371-4859-86eb-04f966e8a7b3",
  "selected_sticker_id": "e7939a2b-07e2-4149-9b01-0ddaecc217eb",
  "washing_processes": [
    {
      "descriptions": {
        "sample string 1": "sample string 2",
        "sample string 3": "sample string 4"
      },
      "active": true,
      "code": "sample string 2",
      "id": "f54c28f2-57eb-42c0-adcd-3f669908ea71",
      "site_id": "6aef7143-e261-43b9-a79a-e316e14472ba"
    },
    {
      "descriptions": {
        "sample string 1": "sample string 2",
        "sample string 3": "sample string 4"
      },
      "active": true,
      "code": "sample string 2",
      "id": "f54c28f2-57eb-42c0-adcd-3f669908ea71",
      "site_id": "6aef7143-e261-43b9-a79a-e316e14472ba"
    }
  ],
  "active": true,
  "certificate_type_id": "76f47e75-8d66-49f8-a5c7-781065d018b7",
  "code": 1,
  "delay_between_scans": 1,
  "id": "33a5141e-87e8-4398-b90b-11dcddf65ad1",
  "internal_reference": "sample string 4",
  "item_wash_max": 1,
  "language_code": "sample string 5",
  "name": "sample string 6",
  "packaging_type_id": "591b1d25-3b7e-4772-bd66-d466baa41d93",
  "packing_type_id": "05fcdec6-6582-4212-9e27-1c084ce16bff",
  "particles_control": true,
  "peremption_month": 1,
  "peremption_print_cleanroom": true,
  "peremption_print_date": true,
  "peremption_print_expedition": true,
  "permanent_management": true,
  "pool_id": "4f4dff2d-3318-40af-b3c6-58e8a6ed4e2a",
  "remark": "sample string 14",
  "site_customer_id": "a03850c3-1643-456c-89af-c2b3148b3f1b",
  "sorting_type_id": "4e3873f2-16b6-44c6-8792-a13663a47b44",
  "type": "sample string 17"
}

application/xml, text/xml

Sample:
<contract xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/EntityModel">
  <active>true</active>
  <certificate_type_id>76f47e75-8d66-49f8-a5c7-781065d018b7</certificate_type_id>
  <code>1</code>
  <delay_between_scans>1</delay_between_scans>
  <id>33a5141e-87e8-4398-b90b-11dcddf65ad1</id>
  <internal_reference>sample string 4</internal_reference>
  <item_wash_max>1</item_wash_max>
  <language_code>sample string 5</language_code>
  <name>sample string 6</name>
  <packaging_type_id>591b1d25-3b7e-4772-bd66-d466baa41d93</packaging_type_id>
  <packing_type_id>05fcdec6-6582-4212-9e27-1c084ce16bff</packing_type_id>
  <particles_control>true</particles_control>
  <peremption_month>1</peremption_month>
  <peremption_print_cleanroom>true</peremption_print_cleanroom>
  <peremption_print_date>true</peremption_print_date>
  <peremption_print_expedition>true</peremption_print_expedition>
  <permanent_management>true</permanent_management>
  <pool_id>4f4dff2d-3318-40af-b3c6-58e8a6ed4e2a</pool_id>
  <remark>sample string 14</remark>
  <site_customer_id>a03850c3-1643-456c-89af-c2b3148b3f1b</site_customer_id>
  <sorting_type_id>4e3873f2-16b6-44c6-8792-a13663a47b44</sorting_type_id>
  <type>sample string 17</type>
  <selected_nameplate_id>cba9d59b-7371-4859-86eb-04f966e8a7b3</selected_nameplate_id>
  <selected_sticker_id>e7939a2b-07e2-4149-9b01-0ddaecc217eb</selected_sticker_id>
  <washing_processes>
    <washing_process>
      <active>true</active>
      <code>sample string 2</code>
      <id>f54c28f2-57eb-42c0-adcd-3f669908ea71</id>
      <site_id>6aef7143-e261-43b9-a79a-e316e14472ba</site_id>
      <descriptions xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
        <d4p1:KeyValueOfstringstring>
          <d4p1:Key>sample string 1</d4p1:Key>
          <d4p1:Value>sample string 2</d4p1:Value>
        </d4p1:KeyValueOfstringstring>
        <d4p1:KeyValueOfstringstring>
          <d4p1:Key>sample string 3</d4p1:Key>
          <d4p1:Value>sample string 4</d4p1:Value>
        </d4p1:KeyValueOfstringstring>
      </descriptions>
    </washing_process>
    <washing_process>
      <active>true</active>
      <code>sample string 2</code>
      <id>f54c28f2-57eb-42c0-adcd-3f669908ea71</id>
      <site_id>6aef7143-e261-43b9-a79a-e316e14472ba</site_id>
      <descriptions xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
        <d4p1:KeyValueOfstringstring>
          <d4p1:Key>sample string 1</d4p1:Key>
          <d4p1:Value>sample string 2</d4p1:Value>
        </d4p1:KeyValueOfstringstring>
        <d4p1:KeyValueOfstringstring>
          <d4p1:Key>sample string 3</d4p1:Key>
          <d4p1:Value>sample string 4</d4p1:Value>
        </d4p1:KeyValueOfstringstring>
      </descriptions>
    </washing_process>
  </washing_processes>
</contract>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

globally unique identifier

Response Formats

application/json, text/json

Sample:
"8ef0ca9d-18d1-4265-83ee-55bfa01055cf"

application/xml, text/xml

Sample:
<guid xmlns="http://schemas.microsoft.com/2003/10/Serialization/">8ef0ca9d-18d1-4265-83ee-55bfa01055cf</guid>