ComplexRulesApi extends ResourceApi
V3ApiBase
Add constructors and some basic scaffolding that will work for all API classes regardless of which endpoints they implement
Table of Contents
- COMPLEX_RULE_ENDPOINT = 'catalog/products/%d/complex-rules/%d'
- COMPLEX_RULES_ENDPOINT = 'catalog/products/%d/complex-rules'
- RESOURCE_NAME = 'complex-rules'
- __construct() : mixed
- create() : ComplexRuleResponse
- get() : ComplexRuleResponse
- getAll() : ComplexRulesResponse
- getClient() : Client
- getParentResourceId() : int|null
- getResourceId() : int|null
- update() : ComplexRuleResponse
Constants
COMPLEX_RULE_ENDPOINT
public
mixed
COMPLEX_RULE_ENDPOINT
= 'catalog/products/%d/complex-rules/%d'
COMPLEX_RULES_ENDPOINT
public
mixed
COMPLEX_RULES_ENDPOINT
= 'catalog/products/%d/complex-rules'
RESOURCE_NAME
public
mixed
RESOURCE_NAME
= 'complex-rules'
Methods
__construct()
public
__construct(Client $client[, int|null $resourceId = null ][, int|null $parentResourceId = null ]) : mixed
Parameters
- $client : Client
- $resourceId : int|null = null
- $parentResourceId : int|null = null
Return values
mixed —create()
public
create(ComplexRule $complexRule) : ComplexRuleResponse
Parameters
- $complexRule : ComplexRule
Return values
ComplexRuleResponse —get()
public
get() : ComplexRuleResponse
Return values
ComplexRuleResponse —getAll()
public
getAll([array<string|int, mixed> $filters = [] ][, int $page = 1 ][, int $limit = 250 ]) : ComplexRulesResponse
Parameters
- $filters : array<string|int, mixed> = []
- $page : int = 1
- $limit : int = 250
Return values
ComplexRulesResponse —getClient()
public
getClient() : Client
Return values
Client —getParentResourceId()
public
getParentResourceId() : int|null
Return values
int|null —getResourceId()
public
getResourceId() : int|null
Return values
int|null —update()
public
update(ComplexRule $complexRule) : ComplexRuleResponse
Parameters
- $complexRule : ComplexRule