# Magento2\SalesRuleCouponManagementV1Api

All URIs are relative to https://magento2.talisman-innovations.com/rest/default.

Method | HTTP request | Description
------------- | ------------- | -------------
[**salesRuleCouponManagementV1DeleteByCodesPost()**](SalesRuleCouponManagementV1Api.md#salesRuleCouponManagementV1DeleteByCodesPost) | **POST** /V1/coupons/deleteByCodes | 
[**salesRuleCouponManagementV1DeleteByIdsPost()**](SalesRuleCouponManagementV1Api.md#salesRuleCouponManagementV1DeleteByIdsPost) | **POST** /V1/coupons/deleteByIds | 
[**salesRuleCouponManagementV1GeneratePost()**](SalesRuleCouponManagementV1Api.md#salesRuleCouponManagementV1GeneratePost) | **POST** /V1/coupons/generate | 


## `salesRuleCouponManagementV1DeleteByCodesPost()`

```php
salesRuleCouponManagementV1DeleteByCodesPost($sales_rule_coupon_management_v1_delete_by_codes_post_body): \Magento2\Model\SalesRuleDataCouponMassDeleteResultInterface
```



Delete coupon by coupon codes.

### Example

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



$apiInstance = new Magento2\Api\SalesRuleCouponManagementV1Api(
    // 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()
);
$sales_rule_coupon_management_v1_delete_by_codes_post_body = new \Magento2\Model\SalesRuleCouponManagementV1DeleteByCodesPostRequest(); // \Magento2\Model\SalesRuleCouponManagementV1DeleteByCodesPostRequest

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

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **sales_rule_coupon_management_v1_delete_by_codes_post_body** | [**\Magento2\Model\SalesRuleCouponManagementV1DeleteByCodesPostRequest**](../Model/SalesRuleCouponManagementV1DeleteByCodesPostRequest.md)|  | [optional]

### Return type

[**\Magento2\Model\SalesRuleDataCouponMassDeleteResultInterface**](../Model/SalesRuleDataCouponMassDeleteResultInterface.md)

### Authorization

No authorization required

### HTTP request headers

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

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

## `salesRuleCouponManagementV1DeleteByIdsPost()`

```php
salesRuleCouponManagementV1DeleteByIdsPost($sales_rule_coupon_management_v1_delete_by_ids_post_body): \Magento2\Model\SalesRuleDataCouponMassDeleteResultInterface
```



Delete coupon by coupon ids.

### Example

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



$apiInstance = new Magento2\Api\SalesRuleCouponManagementV1Api(
    // 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()
);
$sales_rule_coupon_management_v1_delete_by_ids_post_body = new \Magento2\Model\SalesRuleCouponManagementV1DeleteByIdsPostRequest(); // \Magento2\Model\SalesRuleCouponManagementV1DeleteByIdsPostRequest

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

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **sales_rule_coupon_management_v1_delete_by_ids_post_body** | [**\Magento2\Model\SalesRuleCouponManagementV1DeleteByIdsPostRequest**](../Model/SalesRuleCouponManagementV1DeleteByIdsPostRequest.md)|  | [optional]

### Return type

[**\Magento2\Model\SalesRuleDataCouponMassDeleteResultInterface**](../Model/SalesRuleDataCouponMassDeleteResultInterface.md)

### Authorization

No authorization required

### HTTP request headers

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

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

## `salesRuleCouponManagementV1GeneratePost()`

```php
salesRuleCouponManagementV1GeneratePost($sales_rule_coupon_management_v1_generate_post_body): string[]
```



Generate coupon for a rule

### Example

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



$apiInstance = new Magento2\Api\SalesRuleCouponManagementV1Api(
    // 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()
);
$sales_rule_coupon_management_v1_generate_post_body = new \Magento2\Model\SalesRuleCouponManagementV1GeneratePostRequest(); // \Magento2\Model\SalesRuleCouponManagementV1GeneratePostRequest

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

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **sales_rule_coupon_management_v1_generate_post_body** | [**\Magento2\Model\SalesRuleCouponManagementV1GeneratePostRequest**](../Model/SalesRuleCouponManagementV1GeneratePostRequest.md)|  | [optional]

### Return type

**string[]**

### Authorization

No authorization required

### HTTP request headers

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

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