Homepage

ListingsCustomization

Last edit: Oct 26, 2022

No description

type ListingsCustomization implements ListingCustomAttributeInterface, RelationOnDemandInterface, RemoteModelInterface {
  created_at: JSONDate
  custom_address(name: String!): ListingAddress
  custom_addresses(name: String): [ListingAddress!]
  custom_attachment(name: String!): ListingsPrivateFile
  custom_attachments(name: String): [ListingsPrivateFile!]
  custom_image(name: String!): ListingImage
  custom_images(name: String): [ListingImage!]
  custom_model_type: ListingsCustomModelType
  customizable: Customizable
  customizable_id: ID
  customizable_type: String
  customizations(
    filter: NestedCustomizationFilters
    page: Int = 1
    per_page: Int = 20
    sort: [CustomizationsSortOrder]
  ): ListingsCustomizationCollection!
  deleted_at: JSONDate
  external_id: ID
  human_name: String
  id: ID!
  model(
    foreign_property: String = "id"
    join_on_property: String
    model_name: String
  ): ListingsCustomization
  model_schema: ListingsModelSchema
  models(
    foreign_property: String!
    join_on_property: String!
    model_name: [String]
  ): [ListingsCustomization!]
  name: String
  properties: HashObject
  property(name: String!): String
  property_array(name: String!): [String!]
  property_json(name: String!): JSONPayload
  related_model(
    foreign_property: String = "id"
    join_on_property: String
    model_schema_name: String
  ): ListingsCustomization
  related_models(
    foreign_property: String!
    join_on_property: String!
    model_schema_name: [String]
  ): [ListingsCustomization!]
  related_user(
    foreign_property: String = "id"
    join_on_property: String = "user_id"
  ): User
  remote_model(endpoint: Endpoint!, join_on_property: String!): Customization
  updated_at: JSONDate
  user(
    foreign_property: String = "id"
    join_on_property: String = "user_id"
  ): User
  user_id: ID
}

Fields

created_at (JSONDate)

timestamp of when the record was created, automatically generated by the system

custom_address (ListingAddress)

Fetch address by name; ex: address: custom_address(name: "office_address")

custom_addresses (ListingAddress)

Fetch all addresses, optionaly you can filter results by name; ex: home: custom_addresses(name: "home")

custom_attachment (ListingsPrivateFile)

Fetch attachment by name; ex: sales_report: custom_attachment(name: "sales_report")

custom_attachments (ListingsPrivateFile)

custom_image (ListingImage)

Fetch image by name; ex: header: custom_image(name: "header")

custom_images (ListingImage)

Fetch all images, optionaly you can filter results by name; ex: cat_images: custom_images(name: "cat")

custom_model_type (ListingsCustomModelType)

customizable (Customizable)

customizable_id (ID)

customizable_type (String)

customizations (ListingsCustomizationCollection)

deleted_at (JSONDate)

external_id (ID)

Used mainly for import/export, if you want to use third party service as a source of truth

human_name (String)

id (ID)

model (ListingsCustomization)

Defines belongs-to relation with other model; ex: parent: model(model_name:
"parent", join_on_property: "parent_id") { id }

Load resources with foreign_property == join_on_property

Load remote resource with id == join_on_property

Joins model [formaly customization] with custom-model-type-name == model_name

model_schema (ListingsModelSchema)

models (ListingsCustomization)

Defines has-many relation with other model; ex: children: models(model_name:
"child", join_on_property: "parent_id", foreign_property: "parent_id") { id }

Load resources with foreign_property == join_on_property

Load resources with foreign_property == join_on_property

Joins model [formaly customization] with custom-model-type-name == model_name

name (String)

properties (HashObject)

List of all properties assigned to the object.

property (String)

Fetch any custom attribute by name; ex: hair_color: property(name: "hair_color")

property_array (String)

Fetch any property of Array type by name, it returns Array in contrast to
"property" which returns String; ex: todo_list: property_array(name: "todo_list")

property_json (JSONPayload)

Fetch any property of JSON type by name, it returns JSON in contrast to
"property" which returns String; ex: todo_list: property_json(name: "todo_list")

Defines belongs-to relation with other model; ex: parent: model(model_name:
"parent", join_on_property: "parent_id") { id }

Load resources with foreign_property == join_on_property

Load remote resource with id == join_on_property

Joins model [formaly customization] with custom-model-type-name == model_name

Defines has-many relation with other model, returns maximum of 10000 records
at once; ex: children: models(model_name: "child", join_on_property:
"parent_id", foreign_property: "parent_id") { id }

Load resources with foreign_property == join_on_property

Load resources with foreign_property == join_on_property

Joins model [formaly customization] with custom-model-type-name == model_name

Defines relation with other user, returns maximum of 10000 records at once;
ex: invited_by: user(join_on_property: "invited_by_id") { id }

remote_model (Customization)

Defines relation object accessible over HTTP in JSON collection identified by it's ID.

Endpoint that will return resources for given ids in json format

Load remote resource with id == join_on_property

updated_at (JSONDate)

user (User)

Defines relation with other user; ex: invited_by: user(join_on_property: "invited_by_id") { id }

user_id (ID)

Interfaces

ListingCustomAttributeInterface

RelationOnDemandInterface

RemoteModelInterface

Questions?

We are always happy to help with any questions you may have.

contact us