Skip to main content

Fetch organization details

Use the organization query to retrieve high-level information about a workspace once you know its slug. This endpoint is useful for populating UI header copy, confirming you are targeting the correct tenant, or showing basic profile data in logs.

Prerequisites​

  • A valid Naqood API secret scoped to the organization. You can mint one via the OAuth PKCE flow or through Settings → API as described in Authenticate with Secret Keys.
  • The organization's slug, which is returned after OAuth consent and shown in the Naqood dashboard URL (https://app.naqood.ae/<slug>).

Query shape​

Request only the fields you need; the example below keeps it to public metadata (slug, name, and currency).

query OrganizationDetails($slug: Slug!) {
organization(slug: $slug) {
slug
name
currency
}
}

Available fields​

The organization object contains many nested resources. For profile or header displays, these user-facing fields usually cover the need:

Identity & branding​

FieldTypeDescription
slugSlug!Human-readable workspace identifier used in URLs.
nameString!Display name entered by admins.
currencyString!Primary ISO 4217 currency configured for the tenant.

Contact information​

FieldTypeDescription
addressStringStreet address line 1.
address2StringStreet address line 2 / suite.
districtStringDistrict or neighborhood.
cityStringCity or municipality.
postalCodeStringPostal or ZIP code.
countryIdStringCountry identifier; use with the country object if needed.
countryCountryStructured country metadata (code, name, etc.).
emirateStringUAE emirate (if applicable).
emailStringPrimary contact email for the organization.
phoneStringMain phone number.
webStringCompany website URL.

Registration & VAT details​

FieldTypeDescription
companyIdStringGovernment-issued company or trade license number.
vatStringVAT/TRN number recorded in settings.
vatRegisteredAtDateDate the company registered for VAT.
vatQuarterOffsetIntOffset that defines the start of VAT filing quarters.
vatReturnReminderEnabledBoolean!Indicates whether reminder emails are enabled.

Sample request​

Send the GraphQL document and variables to https://app.naqood.ae/graphql with the secret obtained from the OAuth exchange (or an equivalent UI-issued key):

curl https://app.naqood.ae/graphql \
-H "Content-Type: application/json" \
-H "Authorization: Bearer pk_live_public.secret" \
-d '{
"operationName": "OrganizationDetails",
"query": "query OrganizationDetails($slug: Slug!) { organization(slug: $slug) { slug name currency } }",
"variables": { "slug": "acme-co" }
}'

Example response​

{
"data": {
"organization": {
"slug": "acme-co",
"name": "Acme Manufacturing",
"currency": "AED"
}
}
}

If the slug is invalid or you do not have access, the API returns a null organization along with an authorization error message.

Tips​

  • Reuse the same query to verify that a freshly issued token is scoped to the expected organization before performing write operations.
  • Cache the name and currency if you need them frequently, but plan to re-fetch periodically to capture administrative changes.
  • Pair this guide with Authenticate with Secret Keys or OAuth 2.0 Integration to understand how to obtain the bearer token used above.