Request
in package
Class Request
Table of Contents
Properties
- $nextId : mixed
Methods
- create() : AbstractAction|array<string|int, mixed>
- Create a formatted/normalized request object.
- getNextId() : mixed
- normalizeActionName() : string
- Normalize api action name to be lowercase.
- normalizeEntityName() : string
- Normalize entity to be CamelCase.
Properties
$nextId
private
static mixed
$nextId
= 1
Methods
create()
Create a formatted/normalized request object.
public
static create(string $entity, string $action, array<string|int, mixed> $params) : AbstractAction|array<string|int, mixed>
Parameters
- $entity : string
-
API entity name.
- $action : string
-
API action name.
- $params : array<string|int, mixed>
-
API parameters.
Tags
Return values
AbstractAction|array<string|int, mixed>getNextId()
public
static getNextId() : mixed
normalizeActionName()
Normalize api action name to be lowercase.
public
static normalizeActionName(mixed $action) : string
APIv1-v3 munges entity/action names, and accepts any mixture of case and underscores.
Parameters
- $action : mixed
Return values
stringnormalizeEntityName()
Normalize entity to be CamelCase.
public
static normalizeEntityName(string $entity) : string
APIv1-v3 munges entity/action names, and accepts any mixture of case and underscores.
Parameters
- $entity : string