# Update Order Updates existing order. When creating a new order, a regular user has 2 options: - Creating a buy order - Creating a sell order Brokers have the ability to create a direct trade. This enables the broker to do trades between it's own clients. Endpoint: PUT /public-api/1.0/xbid/electricity/orders/{id} Version: 1.0 Security: api-key ## Path parameters: - `id` (string, required) Update order by id. ## Query parameters: - `callbackurl` (string) Callback to return the Id of the order to after initial processing by our system. The callback url will receive a GET request with a parameter named 'id' containing the order Id. Due to the order being created asynchronously, the status cannot be returned by the current http request. After receive of the Id the order can be traced using the Server Sent Event. ## Request fields (application/json): - `orderType` (string, required) The Order type is required field. Enum: "BUY", "SELL" - `xbidOrderType` (string, required) The XBID Order type is required field. Currently supported types include REGULAR and ICEBERG Example: "REGULAR / ICEBERG" - `participantId` (string, required) Example: "292c3db8-3ee1-4999-bbed-d579225d1596" - `capacity` (number, required) The capacity can not be negative and 0. Also the decimal limit of the capacity is 1. The capacity is required field. Example: 2 - `deliveryStartTime` (integer, required) The start time is an epoch time. It is the time in milliseconds since the start of the unix time. The deliveryStartTime time is required field. Example: 1465596000000 - `deliveryEndTime` (integer, required) The end time is an epoch time. It is the time in milliseconds since the start of the unix time. The deliveryEndTime time is required field Example: 1465682400000 - `unitPrice` (number, required) The UnitPrice is required field. Example: 35 - `metadata` (object) Example: {"key1":"value1","key2":"value2"} - `customExpirationTime` (integer) Custom expiration time of an order. If no value is provided then the order will expire 15 minutes before the start time.The time must be a time in the future and must not be later than 15 minutes before the start time. The time provided must be a multiple of 15 minutes. For example 03:00, 03:15, 03:30 and 03:45. Example: 1465682400000 - `orderDeliveryArea` (string, required) Delivery Area Id where the order is located. Enum: "AT", "BG", "BE", "CZ", "DE1", "DE2", "DE3", "DE4", "DK1", "DK2", "EE", "ES", "FI", "FR", "GR", "HR", "HU", "IT1", "IT2", "IT3", "IT4", "IT5", "IT6", "IT7", "IT8", "IT9", "IT10", "IT_AT", "IT_CH", "IT_CP", "IT_FR", "IT_GR", "IT_ME", "IT_SI", "LT", "LV", "MA", "NL", "NO1", "NO2", "NO3", "NO4", "NO5", "PL", "PT", "RO", "RU", "SE1", "SE2", "SE3", "SE4", "SI", "SK" - `orderStatus` (string) The Order status is required field. Enum: "ACTIVE", "HIBERNATE", "WITHDRAWN" - `orderExecution` (string, required) Order execution restriction. Currently only supported types are NON, FOK and IOC Enum: "NON", "FOK", "IOC" - `allowedForLocalMarket` (boolean) When this field is true the order is allowed to go to the local market. If this field is false the order will be rejected and will not be sent to the local market if XBID is down. - `orderVersion` (object) Order validity check - `orderVersion.revisionNo` (integer, required) Order revision number - `orderVersion.xbidOrderId` (integer, required) Xbid order id - `showCapacity` (number) The quantity shown to the market. Only used for XbidOrderType ICEBERG Example: 2 - `pricePerDelta` (number) The peak price delta means that the price of the order can be increased/ decreased with every slice. This field is optional, meaning the default value is 0.0. Example: 2 ## Response 200 fields (application/json): - `href` (string) - `hreflang` (string) - `title` (string) - `type` (string) - `deprecation` (string) - `profile` (string) - `name` (string) - `templated` (boolean) ## Response 412 fields (*/*): - `errors` (array) ## Response 400 fields