ApiDataObject::forApi
This method is used by `ApiController` to get an array of data for the default output.
Override this method on your model to apply custom behavior and fields. By default all fields which are defined on `api_fields` will be used (all field if not defined).
Signature
public function forApi([array
$options = NULL] )
Parameters
$options
— array- optional assoz. array, fields => array of fields
Returns
- array
- $data assoz. array containing data for the output