The attributes.
The requested columns for the query.
Return distinct rows by these columns.
The attributes that are mass assignable.
The attributes that aren't mass assignable
The key name of the parent of this model which was
instantiated from a hasOne or hasMany relation.
This is used to remove the where query when saving
a new entity like parent.$child().save({});
The limit of the number models requested on the query.
The endpoint used when querying the api.
The number of records to be skipped.
The column ordering for the query.
The attribute's original state.
The page number of the paginated models queried.
The loaded relations for the model. The keys do not include the relation prefixes.
The model relations to check for existence.
The backend scopes to be applied on the query.
Indicates if the model should expect a timestamp for soft-deletion.
Indicates if the model should expect timestamps.
The where constraints for the query.
The relations that should be included on every request.
The override to remove the previously added relations from the request.
The requested eager-loaded models for the query.
The name of the created at attribute on the server side.
The name of the deleted at attribute on the server side.
The name of the updated at attribute on the server side.
Property indicating how attributes and relation names should be cast by default.
The attributes that should be cast.
The basic endpoint that model queries.
Indicates whether the model exists on the backend or not.
The attributes that are mass assignable.
The attributes that are not mass assignable.
The type of the key that acts as the primary key of the model.
Boolean flag indicating whether there is an ongoing request or not.
The primary key for the model.
The string all the relation methods expected to prefixed by.
Property indicating how attributes and relation names should be cast by default when sent to the server.
The iterator used for looping over the attributes and relations.
Parse the given data into a related model class and add the relation to this instance.
this
Add a where constraint to the wheres.
Add a string to the end of the string.
Set the endpoint on the correct model for querying.
Set the endpoint on the correct model for querying.
The name of the relation on the backend.
The call method that mediates between the model and api handlers.
Cast the attribute to the specified type.
The method to use when interacting with the AttributeCaster.
Creates a one to one copy of the model without copying by reference.
Compiles the query parameters into a single object.
Create descriptors for the given key(s) therefore allowing magic access.
Delete the model.
Remove the attribute and its magic access if set.
Request only distinct values on the query based on the given columns.
Get all model attributes except the given keys.
Fill the model with the given attributes while respecting the guarding settings.
Find the model based on the given id.
Return multiple models based on the given ids.
Set the endpoint to a nested url structure.
this
Fill the model with the given attributes without respecting the guarding settings.
Refresh the timestamps from remote.
Send a GET request to the endpoint.
Get an attribute from the model.
Get available attribute keys.
Get all the attributes on the model.
Get the type of cast for a model attribute.
Get the attributes that were changed.
Get the name of the created at attribute.
Get the name of the deleted at attribute.
Get the deleted attributes if any.
Get the endpoint for the model.
Get the fillable attributes for the model.
Get the fillable attributes from the given object.
Get the guarded attributes for the model.
Get the primary key for the model.
Get the primary key for the model.
Get the polymorphic column names.
Gets the current class' name.
For more information check the documentation
Get the new attributes if any.
Get the original attributes.
Get all the attributes on the model without casting or accessors.
Get the original attributes without casting.
Get the specified relationship.
Get the name of the relation type for the given relation.
Get all the relations.
Get the name of the updated at attribute.
Guess the foreign key name that would be used to reference this model.
Add a has check of the related records
Determine whether an attribute should be cast to a determined type.
Determine whether the given attribute has changed or attributes has been added or deleted.
Determine if a get accessor exists for an attribute.
Set the endpoint on the correct model for querying.
Set the endpoint on the correct model for querying.
Determine if a set mutator exists for an attribute.
Determine whether the given value implements casting.
Determine if two models have the same key and of the same type.
Determine whether given or any attributes was changed.
Alias for the hasChanges method.
Determine if the given attribute may be mass assignable.
Determine if the given attribute may not be mass assignable.
Determine if two models are not the same.
An alias for the orderByDesc method.
Set the limit for the returned models on the next request.
Load a relationships from remote.
Whether the already loaded relations should also be reloaded.
Get an array of loaded relation names.
Merge new fillable attributes with existing fillable attributes on the model.
Merge new guarded attributes with existing guarded attributes on the model.
Set the endpoint on the correct model for querying.
Set the endpoint on the correct model for querying.
Add a constraint for the next query to return all relation.
Construct a new model from context.
Parse the data into a model or model collection.
The offset of the records sent back.
Add an ordering by ascending of the records for the query.
Get a subset of the model's attributes.
Add an or where closure to the query.
Add an or where between closure to the query.
Add an or where in closure to the query.
Add an or where key closure to the query.
Add a where key not closure to the query.
Add an or where not between closure to the query.
Add an or where not in closure to the query.
Add an or where not null closure to the query.
Add an or where null closure to the query.
Add an ordering of the records for the query.
Add an ordering by descending of the records for the query.
Set the page of the returned models for the next request.
Send a PATCH request to the endpoint.
Send a POST request to the endpoint.
Send a PUT request to the endpoint.
Refresh the attributes from the backend.
Assert whether the relation has been defined on this instance.
Determine if the given relation is loaded.
Remove the relation and its magic access if set.
Clone the model into a non-exiting instance.
Reset the attributes to the original values.
Reset the endpoint to the original expected string.
Reset the request parameters.
Set the deleted at attribute to null on remote.
Save or update the model.
Add eager loaded relations to the query.
Tell the api which columns are required.
Set the endpoint for the model.
Set the fillable attributes for the model.
Set the guarded attributes for the model.
Set the last synced at attribute.
Utility to cast the given string to the serverAttributeCasing's case.
Utility to cast the given string to the attributeCasing's case.
An alias for the offset method.
Sync the original attributes with the current.
Throw an error if the model does not exists before calling the specified method.
Show the model in a human-readable string representation.
Update the timestamps on remote.
Utility to recursively format the keys according to the server argument.
The object which should
whether to use the serverAttributeCasing or attributeCasing
Determine if the model instance has been soft-deleted.
Set the correct endpoint and initiate a patch request.
Determine if the model uses soft deletes timestamp.
Determine if the model uses timestamps.
Add a where constraint to the query.
Add a where between closure to the query.
Add a where in closure to the query.
Add a where key closure to the query.
Add a where key not closure to the query.
Add a where not between closure to the query.
Add a where not in closure to the query.
Add a where not null closure to the query.
Add a where null closure to the query.
Add eager loaded relations to the query.
Remove eager loaded relations from the query.
Get all the models.
Construct a new model instance.
The static version of the distinct method.
Call the factory fluently from the model.
The static version of the find method.
The static version of the findMany method.
The get method made available as a static method.
append and/or overwrite query parameter values.
The static version of the has method.
The static version of the latest method.
The static version of the limit method.
Return the instantiated class.
The static version of the offset method.
The static version of the oldest method.
The static version of the orderBy method.
The static version of the orderByDesc method.
The static version of the page method.
The static version of the scope method.
The static version of the select method.
The static version of the skip method.
The static version of the unless method.
The static version of the when method.
The static version of the where method.
The static version of the whereBetween method.
The static version of the whereIn method.
The static version of the whereKey method.
The static version of the whereKeyNot method.
The static version of the whereNotBetween method.
The static version of the whereNotIn method.
The static version of the whereNotNull method.
The static version of the whereNull method.
The static version of the with method.
The static version of the with method.
Generated using TypeDoc
The attributes that should be cast.