# Fortnox\FortnoxWayOfDeliveriesApi



All URIs are relative to https://api.fortnox.se, except if the operation defines another base path.

| Method | HTTP request | Description |
| ------------- | ------------- | ------------- |
| [**wayOfDeliveryControllerDoCreate()**](FortnoxWayOfDeliveriesApi.md#wayOfDeliveryControllerDoCreate) | **POST** /3/wayofdeliveries | Create a way of delivery |
| [**wayOfDeliveryControllerDoDelete()**](FortnoxWayOfDeliveriesApi.md#wayOfDeliveryControllerDoDelete) | **DELETE** /3/wayofdeliveries/{Code} | Remove a way of delivery |
| [**wayOfDeliveryControllerDoIndex()**](FortnoxWayOfDeliveriesApi.md#wayOfDeliveryControllerDoIndex) | **GET** /3/wayofdeliveries | Retrieve a list of way of deliveries |
| [**wayOfDeliveryControllerDoShow()**](FortnoxWayOfDeliveriesApi.md#wayOfDeliveryControllerDoShow) | **GET** /3/wayofdeliveries/{Code} | Retrieve a single way of delivery |
| [**wayOfDeliveryControllerDoUpdate()**](FortnoxWayOfDeliveriesApi.md#wayOfDeliveryControllerDoUpdate) | **PUT** /3/wayofdeliveries/{Code} | Update a way of delivery |


## `wayOfDeliveryControllerDoCreate()`

```php
wayOfDeliveryControllerDoCreate($way_of_delivery): \Fortnox\Model\FortnoxWayOfDeliverySingleItemWrap
```

Create a way of delivery

Create a way of delivery

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');



$apiInstance = new Fortnox\Api\FortnoxWayOfDeliveriesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$way_of_delivery = new \Fortnox\Model\FortnoxWayOfDeliverySinglePayloadItemWrap(); // \Fortnox\Model\FortnoxWayOfDeliverySinglePayloadItemWrap | Request body for create way of delivery

try {
    $result = $apiInstance->wayOfDeliveryControllerDoCreate($way_of_delivery);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FortnoxWayOfDeliveriesApi->wayOfDeliveryControllerDoCreate: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **way_of_delivery** | [**\Fortnox\Model\FortnoxWayOfDeliverySinglePayloadItemWrap**](../Model/FortnoxWayOfDeliverySinglePayloadItemWrap.md)| Request body for create way of delivery | [optional] |

### Return type

[**\Fortnox\Model\FortnoxWayOfDeliverySingleItemWrap**](../Model/FortnoxWayOfDeliverySingleItemWrap.md)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `wayOfDeliveryControllerDoDelete()`

```php
wayOfDeliveryControllerDoDelete($code)
```

Remove a way of delivery

Delete a way of delivery

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');



$apiInstance = new Fortnox\Api\FortnoxWayOfDeliveriesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$code = 'code_example'; // string | Code of way of delivery to delete

try {
    $apiInstance->wayOfDeliveryControllerDoDelete($code);
} catch (Exception $e) {
    echo 'Exception when calling FortnoxWayOfDeliveriesApi->wayOfDeliveryControllerDoDelete: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **code** | **string**| Code of way of delivery to delete | |

### Return type

void (empty response body)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `wayOfDeliveryControllerDoIndex()`

```php
wayOfDeliveryControllerDoIndex(): \Fortnox\Model\FortnoxWayOfDeliveryListItemWrap
```

Retrieve a list of way of deliveries

The way of delivery register can return a list of records or a single record. By specifying a Code in the URL, a single record will be returned. Not specifying a Code will return a list of records.

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');



$apiInstance = new Fortnox\Api\FortnoxWayOfDeliveriesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);

try {
    $result = $apiInstance->wayOfDeliveryControllerDoIndex();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FortnoxWayOfDeliveriesApi->wayOfDeliveryControllerDoIndex: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

This endpoint does not need any parameter.

### Return type

[**\Fortnox\Model\FortnoxWayOfDeliveryListItemWrap**](../Model/FortnoxWayOfDeliveryListItemWrap.md)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `wayOfDeliveryControllerDoShow()`

```php
wayOfDeliveryControllerDoShow($code): \Fortnox\Model\FortnoxWayOfDeliverySingleItemWrap
```

Retrieve a single way of delivery

Retrieve a way of delivery

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');



$apiInstance = new Fortnox\Api\FortnoxWayOfDeliveriesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$code = 'code_example'; // string | Code of way of delivery to show

try {
    $result = $apiInstance->wayOfDeliveryControllerDoShow($code);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FortnoxWayOfDeliveriesApi->wayOfDeliveryControllerDoShow: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **code** | **string**| Code of way of delivery to show | |

### Return type

[**\Fortnox\Model\FortnoxWayOfDeliverySingleItemWrap**](../Model/FortnoxWayOfDeliverySingleItemWrap.md)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)

## `wayOfDeliveryControllerDoUpdate()`

```php
wayOfDeliveryControllerDoUpdate($code, $way_of_delivery): \Fortnox\Model\FortnoxWayOfDeliverySingleItemWrap
```

Update a way of delivery

Update a way of delivery

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');



$apiInstance = new Fortnox\Api\FortnoxWayOfDeliveriesApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$code = 'code_example'; // string | Code of way of delivery to update
$way_of_delivery = new \Fortnox\Model\FortnoxWayOfDeliverySinglePayloadItemWrap(); // \Fortnox\Model\FortnoxWayOfDeliverySinglePayloadItemWrap | Request body for update way of delivery

try {
    $result = $apiInstance->wayOfDeliveryControllerDoUpdate($code, $way_of_delivery);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FortnoxWayOfDeliveriesApi->wayOfDeliveryControllerDoUpdate: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **code** | **string**| Code of way of delivery to update | |
| **way_of_delivery** | [**\Fortnox\Model\FortnoxWayOfDeliverySinglePayloadItemWrap**](../Model/FortnoxWayOfDeliverySinglePayloadItemWrap.md)| Request body for update way of delivery | [optional] |

### Return type

[**\Fortnox\Model\FortnoxWayOfDeliverySingleItemWrap**](../Model/FortnoxWayOfDeliverySingleItemWrap.md)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: `application/json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)
