# Vend\PromoCodeApi



All URIs are relative to https://example.retail.lightspeed.app/api/2026-07, except if the operation defines another base path.

| Method | HTTP request | Description |
| ------------- | ------------- | ------------- |
| [**deletePromoCodesBulk()**](PromoCodeApi.md#deletePromoCodesBulk) | **DELETE** /promocode/bulk | Delete promo codes |
| [**getActivePromoCodesBulk()**](PromoCodeApi.md#getActivePromoCodesBulk) | **POST** /promocode/bulk/active | Get the active status of promo codes |


## `deletePromoCodesBulk()`

```php
deletePromoCodesBulk($request_body): string[]
```

Delete promo codes

Delete promo codes, by promocode IDs  🔒 Requires: `promotions:write` scope

### Example

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


// Configure Bearer (JWT) authorization: bearerAuth
$config = Vend\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new Vend\Api\PromoCodeApi(
    // 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(),
    $config
);
$request_body = array('request_body_example'); // string[]

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

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **request_body** | [**string[]**](../Model/string.md)|  | |

### Return type

**string[]**

### Authorization

[bearerAuth](../../README.md#bearerAuth)

### HTTP request headers

- **Content-Type**: `application/json`
- **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)

## `getActivePromoCodesBulk()`

```php
getActivePromoCodesBulk($request_body): array<string,bool>
```

Get the active status of promo codes

Get promo codes, with their associated promotions.  🔒 Requires: `promotions:read` scope

### Example

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


// Configure Bearer (JWT) authorization: bearerAuth
$config = Vend\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new Vend\Api\PromoCodeApi(
    // 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(),
    $config
);
$request_body = array('request_body_example'); // string[]

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

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **request_body** | [**string[]**](../Model/string.md)|  | |

### Return type

**array<string,bool>**

### Authorization

[bearerAuth](../../README.md#bearerAuth)

### HTTP request headers

- **Content-Type**: `application/json`
- **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)
