30 days free. No credit card. Full access from the moment you connect your site.

Start free trial

GeoDirectory List Listing Fields

geodirectory/list-listing-fields returns the custom-field definitions for a listing type. It is the authoritative schema for that type.

Every listing write in this suite depends on it.

At a glance

Abilitygeodirectory/list-listing-fields
ToolsetGeoDirectory — toolset/geodirectory
GroupGeoDirectory › Fields
RequiresAcrossAI Pro, plus GeoDirectory active on the site
Capabilitymanage_options
SafetyRead-only — changes nothing
RepeatableIdempotent — running it twice leaves the same result
Ships inAcrossAI Pro 0.9.16 and later

How it works

GeoDirectory fields are defined per site and per listing type. There is no fixed schema to know in advance, which is why geodirectory/list-listing-fields is the call before any listing write: it returns the accepted keys, and each row’s name — its htmlvar_name — is what you write under.

Each row’s name is the key to write under, and it is also the database column name — GeoDirectory stores listing fields in a real table with real columns rather than in post meta.

That is why the field abilities are schema operations rather than settings, and why deleting a field destroys data.

The form-layout properties come back too: order, required, placement and placeholder. Those control how the add-listing form renders, which is what you need before changing the form rather than the data.

The default page size is the route maximum, because a caller asking for a schema almost always wants all of it. A type with more than a hundred fields needs paging.

Input

NameTypeRequiredWhat it is
post_typestringNoListing type, for example gd_place. Defaults to the site default. See geodirectory/get-directory-overview for the valid values.
locationstringNoOnly fields shown in this output location.
searchstringNoFree-text search across field titles.
per_pageintegerNoRows per page. Defaults to the route maximum.
pageintegerNoPage number.

What comes back

NameTypeWhat it is
fieldsarrayEach field with its name, type, titles, requirement, ordering and placement.
totalintegerHow many fields the type has.
successbooleanWhether the call completed.
messagestringA one-line summary of what happened, suitable for showing a human.
error_codestringPresent only on failure — a stable machine-readable reason, such as a missing field, a wrong field type or an unmet confirmation.

Example

Ask your assistant:

What fields can I set on a listing here?

It resolves to one call:

{
  "ability": "geodirectory/list-listing-fields",
  "parameters": {}
}

Worth knowing

  • The name is both the write key and the database column.
  • Fields differ per listing type. Read per type.
  • The default page size is the route maximum, deliberately.
  • Read-only.

Related abilities


Get the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager

Browse the rest: Every ability, by category


Keep reading