POST api/v2/order

Creates new order for data to download

Request Information

URI Parameters

None.

Body Parameters

OrderType model

Geonorge.NedlastingApi.V2.OrderType
NameDescriptionTypeAdditional information
email

string

None.

orderLines

Collection of Geonorge.NedlastingApi.V2.OrderLineType

None.

_links

Collection of Geonorge.NedlastingApi.V2.LinkType

None.

Request Formats

application/json, text/json

Sample:
{
  "email": "bruker@epost.no",
  "orderLines": [
    {
      "areas": [
        {
          "code": "02",
          "name": "Akershus",
          "type": "fylke"
        }
      ],
      "formats": [
        {
          "name": "SOSI 4.5"
        },
        {
          "name": "GML 3.2.1"
        }
      ],
      "metadataUuid": "041f1e6e-bdbc-4091-b48f-8a5990f3cc5b",
      "projections": [
        {
          "code": "25832",
          "name": "EUREF89 UTM sone 32, 2d",
          "codespace": "http://www.opengis.net/def/crs/EPSG/0/25832"
        },
        {
          "code": "25833",
          "name": "EUREF89 UTM sone 33, 2d",
          "codespace": "http://www.opengis.net/def/crs/EPSG/0/25833"
        },
        {
          "code": "25835",
          "name": "EUREF89 UTM sone 35, 2d",
          "codespace": "http://www.opengis.net/def/crs/EPSG/0/25835"
        }
      ]
    }
  ]
}

application/xml, text/xml

Sample:
<Order xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://skjema.geonorge.no/SOSI/tjenestespesifikasjon/nedlastingapi/2.0">
  <email>bruker@epost.no</email>
  <orderLines>
    <orderline>
      <areas>
        <orderarea>
          <code>02</code>
          <name>Akershus</name>
          <type>fylke</type>
          <_links xsi:nil="true" />
        </orderarea>
      </areas>
      <formats>
        <format>
          <name>SOSI 4.5</name>
          <_links xsi:nil="true" />
        </format>
        <format>
          <name>GML 3.2.1</name>
          <_links xsi:nil="true" />
        </format>
      </formats>
      <metadataUuid>041f1e6e-bdbc-4091-b48f-8a5990f3cc5b</metadataUuid>
      <projections>
        <projection>
          <code>25832</code>
          <name>EUREF89 UTM sone 32, 2d</name>
          <codespace>http://www.opengis.net/def/crs/EPSG/0/25832</codespace>
          <_links xsi:nil="true" />
        </projection>
        <projection>
          <code>25833</code>
          <name>EUREF89 UTM sone 33, 2d</name>
          <codespace>http://www.opengis.net/def/crs/EPSG/0/25833</codespace>
          <_links xsi:nil="true" />
        </projection>
        <projection>
          <code>25835</code>
          <name>EUREF89 UTM sone 35, 2d</name>
          <codespace>http://www.opengis.net/def/crs/EPSG/0/25835</codespace>
          <_links xsi:nil="true" />
        </projection>
      </projections>
      <_links xsi:nil="true" />
    </orderline>
  </orderLines>
  <_links xsi:nil="true" />
</Order>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'System.Web.Http.ModelBinding.JQueryMvcFormUrlEncodedFormatter' to write type 'OrderType'.

Response Information

Resource Description

OrderReceiptType model with orderreference and a list of files to download if they are prepopulated, otherwise the files are delivered via email

Geonorge.NedlastingApi.V2.OrderReceiptType
NameDescriptionTypeAdditional information
referenceNumber

string

None.

files

Collection of Geonorge.NedlastingApi.V2.FileType

None.

email

string

None.

orderDate

date

None.

_links

Collection of Geonorge.NedlastingApi.V2.LinkType

None.

Response Formats

application/json, text/json

Sample:
{
  "referenceNumber": "O-123456789",
  "files": [
    {
      "downloadUrl": "nedlastbarURI",
      "fileSize": "12345",
      "name": "AdministrativeEnheter_02_32.gml"
    },
    {
      "downloadUrl": "nedlastbarURI",
      "fileSize": "12345",
      "name": "AdministrativeEnheter_02_32.sos"
    },
    {
      "downloadUrl": "nedlastbarURI",
      "fileSize": "12345",
      "name": "AdministrativeEnheter_02_33.gml"
    },
    {
      "downloadUrl": "nedlastbarURI",
      "fileSize": "12345",
      "name": "AdministrativeEnheter_02_33.sos"
    },
    {
      "downloadUrl": "nedlastbarURI",
      "fileSize": "12345",
      "name": "AdministrativeEnheter_02_35.gml"
    },
    {
      "downloadUrl": "nedlastbarURI",
      "fileSize": "12345",
      "name": "AdministrativeEnheter_02_35.sos"
    }
  ],
  "orderDate": "0001-01-01T00:00:00"
}

application/xml, text/xml

Sample:
<OrderReceipt xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://skjema.geonorge.no/SOSI/tjenestespesifikasjon/nedlastingapi/2.0">
  <referenceNumber>O-123456789</referenceNumber>
  <files>
    <file>
      <downloadUrl>nedlastbarURI</downloadUrl>
      <fileSize>12345</fileSize>
      <name>AdministrativeEnheter_02_32.gml</name>
      <fileId xsi:nil="true" />
      <metadataUuid xsi:nil="true" />
      <area xsi:nil="true" />
      <areaName xsi:nil="true" />
      <coordinates xsi:nil="true" />
      <projection xsi:nil="true" />
      <projectionName xsi:nil="true" />
      <format xsi:nil="true" />
      <status xsi:nil="true" />
      <_links xsi:nil="true" />
    </file>
    <file>
      <downloadUrl>nedlastbarURI</downloadUrl>
      <fileSize>12345</fileSize>
      <name>AdministrativeEnheter_02_32.sos</name>
      <fileId xsi:nil="true" />
      <metadataUuid xsi:nil="true" />
      <area xsi:nil="true" />
      <areaName xsi:nil="true" />
      <coordinates xsi:nil="true" />
      <projection xsi:nil="true" />
      <projectionName xsi:nil="true" />
      <format xsi:nil="true" />
      <status xsi:nil="true" />
      <_links xsi:nil="true" />
    </file>
    <file>
      <downloadUrl>nedlastbarURI</downloadUrl>
      <fileSize>12345</fileSize>
      <name>AdministrativeEnheter_02_33.gml</name>
      <fileId xsi:nil="true" />
      <metadataUuid xsi:nil="true" />
      <area xsi:nil="true" />
      <areaName xsi:nil="true" />
      <coordinates xsi:nil="true" />
      <projection xsi:nil="true" />
      <projectionName xsi:nil="true" />
      <format xsi:nil="true" />
      <status xsi:nil="true" />
      <_links xsi:nil="true" />
    </file>
    <file>
      <downloadUrl>nedlastbarURI</downloadUrl>
      <fileSize>12345</fileSize>
      <name>AdministrativeEnheter_02_33.sos</name>
      <fileId xsi:nil="true" />
      <metadataUuid xsi:nil="true" />
      <area xsi:nil="true" />
      <areaName xsi:nil="true" />
      <coordinates xsi:nil="true" />
      <projection xsi:nil="true" />
      <projectionName xsi:nil="true" />
      <format xsi:nil="true" />
      <status xsi:nil="true" />
      <_links xsi:nil="true" />
    </file>
    <file>
      <downloadUrl>nedlastbarURI</downloadUrl>
      <fileSize>12345</fileSize>
      <name>AdministrativeEnheter_02_35.gml</name>
      <fileId xsi:nil="true" />
      <metadataUuid xsi:nil="true" />
      <area xsi:nil="true" />
      <areaName xsi:nil="true" />
      <coordinates xsi:nil="true" />
      <projection xsi:nil="true" />
      <projectionName xsi:nil="true" />
      <format xsi:nil="true" />
      <status xsi:nil="true" />
      <_links xsi:nil="true" />
    </file>
    <file>
      <downloadUrl>nedlastbarURI</downloadUrl>
      <fileSize>12345</fileSize>
      <name>AdministrativeEnheter_02_35.sos</name>
      <fileId xsi:nil="true" />
      <metadataUuid xsi:nil="true" />
      <area xsi:nil="true" />
      <areaName xsi:nil="true" />
      <coordinates xsi:nil="true" />
      <projection xsi:nil="true" />
      <projectionName xsi:nil="true" />
      <format xsi:nil="true" />
      <status xsi:nil="true" />
      <_links xsi:nil="true" />
    </file>
  </files>
  <orderDate>0001-01-01T00:00:00</orderDate>
  <_links xsi:nil="true" />
</OrderReceipt>