API Reference

users

5 endpoints

  • /api/v1/users
GET/api/v1/users/{username}

Get User

Scope: user:read

Get a user by username.

Readable by any caller holding user:read. UserResponse carries only what a user publishes about themselves; their own account record is at /users/me.

Path parameters

username*string

Query parameters

default_backendstring

default: "primary"

Responses

200Successful Response
FieldTypeDescription
uuid*string
username*string
first_name*string
last_namestring | null
account_type*enum
avatar_image_file_uuidstring | null

UUID of the avatar image file if backed by a stored file, derived from the primary profile; null for external or no avatar.

avatar_image_file_urlstring | null

Avatar image URL derived from the primary profile.

created_at*string (date-time)
updated_atstring (date-time) | null
401Authentication failed
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

403Insufficient permissions
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

404Resource not found
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

422Validation error
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

Example request

curl -X GET "https://api.davi.social/api/v1/users/{username}" \
  -H "Authorization: Bearer <token>"
GET/api/v1/users/{username}/profile

Get User Profile

Scope: profile:read

Get a user's profile page.

Public by design — this is what a shared profile link resolves to, so any caller holding profile:read may read it and no ownership check applies. A locked profile is suppressed here even though its owner can still see it.

A name held by an organization is not found here, deliberately. Users and organizations share one namespace, so a well-formed name that nobody can be shown is a real answer rather than a gap — organizations have addresses but no page behind them yet. This is the route that changes when they get one; until then the lookup is by account and an organization's name reaches no account, which is the 404.

The published read of a profile; composing one is Davi's own editor and is not part of this API.

Carries profile_page_uuid, which is what POST /contacts takes to save the person behind the page.

Path parameters

username*string

Query parameters

default_backendstring

default: "primary"

Responses

200Successful Response
FieldTypeDescription
viewer_has_exchangedboolean

Whether this viewer has explicitly exchanged with this profile.

default: false

document*ProfileDocument-Output

The structured v2 profile document

object · ProfileDocument-Output

FieldTypeDescription
version*integer

Profile schema version

default: 2

theme*ProfileTheme-Output

Profile theme settings

object · ProfileTheme-Output

FieldTypeDescription
template_uuid*string (uuid) | null

Live link to base template identifier; null uses platform default

overrides*ProfileThemeOverrides-Output

Theme overrides

identity*ProfileIdentity-Output

Profile identity details

object · ProfileIdentity-Output

FieldTypeDescription
display_name*string

Profile display name

default: ""

avatar*UploadRef-Output | UserAssetRef-Output | OrgAssetRef-Output | TemplateAssetRef-Output | ExternalRef-Output | null

Profile avatar asset

avatar_frame*UploadRef-Output | UserAssetRef-Output | OrgAssetRef-Output | TemplateAssetRef-Output | ExternalRef-Output | null

Decorative avatar frame asset

headline*string

Headline or bio text formatted as inline markdown

default: ""

role*ProfileRole-Output | null

Current professional role

pages*ProfileDocumentPage-Output[]

Profile pages

array items · ProfileDocumentPage-Output

FieldTypeDescription
id*string

Page identifier

default: "home"

slug*string

URL slug for the page

default: ""

sections*MainSection-Output[]

Sections in this page

stickers*object[]

Decorative stickers

feature_sourcesProfileFeatureSources-Output | null

Server-managed provenance for gated profile features; read-only for clients

object · ProfileFeatureSources-Output

FieldTypeDescription
connect_omission*ConnectOmissionSource | null

Server-managed provenance for a template-seeded connect omission; read-only for clients

effective_documentProfileDocument-Output | null

Owner-only presentation projection: the document with an omitted connect restored and authoring metadata removed, when it differs from the authored document. Never accepted by a save.

object · ProfileDocument-Output

FieldTypeDescription
version*integer

Profile schema version

default: 2

theme*ProfileTheme-Output

Profile theme settings

object · ProfileTheme-Output

FieldTypeDescription
template_uuid*string (uuid) | null

Live link to base template identifier; null uses platform default

overrides*ProfileThemeOverrides-Output

Theme overrides

identity*ProfileIdentity-Output

Profile identity details

object · ProfileIdentity-Output

FieldTypeDescription
display_name*string

Profile display name

default: ""

avatar*UploadRef-Output | UserAssetRef-Output | OrgAssetRef-Output | TemplateAssetRef-Output | ExternalRef-Output | null

Profile avatar asset

avatar_frame*UploadRef-Output | UserAssetRef-Output | OrgAssetRef-Output | TemplateAssetRef-Output | ExternalRef-Output | null

Decorative avatar frame asset

headline*string

Headline or bio text formatted as inline markdown

default: ""

role*ProfileRole-Output | null

Current professional role

pages*ProfileDocumentPage-Output[]

Profile pages

array items · ProfileDocumentPage-Output

FieldTypeDescription
id*string

Page identifier

default: "home"

slug*string

URL slug for the page

default: ""

sections*MainSection-Output[]

Sections in this page

stickers*object[]

Decorative stickers

feature_sourcesProfileFeatureSources-Output | null

Server-managed provenance for gated profile features; read-only for clients

object · ProfileFeatureSources-Output

FieldTypeDescription
connect_omission*ConnectOmissionSource | null

Server-managed provenance for a template-seeded connect omission; read-only for clients

feature_statusProfileFeatureStatus | null

Owner-only state of the paid features this profile uses. Absent on every other viewer's response.

object · ProfileFeatureStatus

FieldTypeDescription
featuresProfileFeatureState[]

Affected owner features, in stable order

array items · ProfileFeatureState

FieldTypeDescription
key*enum

Owner feature the status describes

state*enum

Active while the plan grants it, grace while a retained effect still renders after losing it, inactive once it no longer applies

stops_atstring (date-time) | null

When the effect stops, for a grace or inactive feature; null while the plan still grants it

grace_ends_atstring (date-time) | null

End of the current grace window, if any

mediaProfileMediaResponse | null

Display URLs for the document's avatar, avatar frame and background, resolved from the profile's validated sources. The document keeps the references; clients render from this and never write it back.

object · ProfileMediaResponse

FieldTypeDescription
avatar_url*string | null

Hydrated avatar image URL

avatar_frame_url*string | null

Hydrated avatar frame image URL

background*CssBackground-Output | null

Hydrated background CSS representation

object · CssBackground-Output

FieldTypeDescription
source*string

CSS-based background styling

default: "css"

background*string | null

CSS background shorthand value

background_color*string | null

CSS background color

background_image*string | null

CSS background image value

background_position*string | null

CSS background position

background_size*string | null

CSS background size

background_repeat*string | null

CSS background repeat

background_attachment*string | null

CSS background attachment

avatar_fallback*boolean

Whether avatar uses platform fallback

default: false

avatar_frame_fallback*boolean

Whether avatar frame uses platform fallback

default: false

background_fallback*boolean

Whether background uses platform fallback

default: false

theme*ProfileMediaTheme

Effective theme resolved in the same generation as the media

object · ProfileMediaTheme

FieldTypeDescription
palette*object

Effective palette colors for the profile; keys left out use the platform default

custom_css*SanitizedProfileCssV1 | null

Effective compiled stylesheet: eligible template rules followed by the owner's, or null when neither applies

media_version*string

Stable digest of the effective palette, media sources and styling

revisioninteger

Current revision number of the profile page

default: 1

profile_page_uuidstring | null

UUID of the profile page (for use in save-contact flows)

is_lockedboolean

True when the profile was issued by an organization and the owner's membership in that org is inactive. Derived at read time.

default: false

primary_card_uidstring | null

Identifier of the owner's primary card — the `uid` in /c/{uid} URLs. Lets the profile page advertise the card+json discovery link (/c/{uid}/json). NULL for bearer profiles and owners with no primary card.

updated_atstring (date-time) | null

When the profile was last written. Moves on any edit, including one that replaces an image while leaving its url the same — which is what makes it usable for cache keys that a url alone cannot invalidate.

401Authentication failed
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

403Insufficient permissions
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

404Resource not found
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

422Validation error
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

Example request

curl -X GET "https://api.davi.social/api/v1/users/{username}/profile" \
  -H "Authorization: Bearer <token>"
GET/api/v1/users/me

Get Current User

Scope: user:read

Get the currently authenticated user.

Query parameters

default_backendstring

default: "primary"

Responses

200Successful Response
FieldTypeDescription
uuid*string

User UUID

usernamestring | null

Username (set during onboarding)

first_namestring | null

First name (set during onboarding)

last_namestring | null

Last name

phone_numberstring | null

Phone number

avatar_image_file_urlstring | null

Avatar image URL derived from the primary profile.

created_at*string (date-time)

Account creation timestamp

iam_user_idstring | null

IAM user ID (without 'iam:' prefix)

emailstring | null

Email address from auth provider

email_verifiedboolean | null

Whether email is verified

scopesstring[]

Granted permission scopes

wallet_addressstring | null

Primary wallet address

primary_card_identifierstring | null

Primary card identifier (e.g., NFC serial number)

profile_complete*boolean

Whether user has completed their profile setup

onboarding_requiredboolean

Whether user needs to complete onboarding

default: false

subscription*CurrentSubscriptionResponse

The user's subscription tier and entitlements

object · CurrentSubscriptionResponse

FieldTypeDescription
tier*string

The user's Davi subscription tier. One of a fixed set Davi declares — not an organization's membership tier, which is addressed by uuid or slug and varies per organization.

display_name*string
status*string
started_at*string (date-time)
valid_untilstring (date-time) | null
entitlements*PlatformEntitlements

object · PlatformEntitlements

FieldTypeDescription
custom_backgroundsboolean

default: false

custom_cssboolean

default: false

remove_connectboolean

default: false

max_profilesinteger

default: 1

max_pagesinteger

default: 1

extrasobject
401Authentication failed
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

403Insufficient permissions
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

404Resource not found
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

422Validation error
FieldTypeDescription
errors*object

Map of field names to error messages. Use '_root' for form-level errors.

message*string

Human-readable error summary

codestring | null

Machine-readable error code

detailsobject | null

What the refusal is about, where it is something you can act on — the amount and currency owed on a `402`, the entitlement a tier did not grant on a `403`. Values are typed as the error carries them, so read a figure from here rather than from `errors`, whose values are always the copy a form shows against a field.

Example request

curl -X GET "https://api.davi.social/api/v1/users/me" \
  -H "Authorization: Bearer <token>"
GET/api/v1/users/me/subscription

Get My Subscription

Scope: user:read

Get the current user's subscription tier and entitlements.

Query parameters

default_backendstring

default: "primary"

Responses

200Successful Response
FieldTypeDescription
tier*string

The user's Davi subscription tier. One of a fixed set Davi declares — not an organization's membership tier, which is addressed by uuid or slug and varies per organization.

display_name*string
status*string
started_at*string (date-time)
valid_untilstring (date-time) | null
entitlements*PlatformEntitlements

object · PlatformEntitlements

FieldTypeDescription
custom_backgroundsboolean

default: false

custom_cssboolean

default: false

remove_connectboolean

default: false

max_profilesinteger

default: 1

max_pagesinteger

default: 1

extrasobject
422Validation Error
FieldTypeDescription
detailValidationError[]

array items · ValidationError

FieldTypeDescription
loc*string | integer[]
msg*string
type*string

Example request

curl -X GET "https://api.davi.social/api/v1/users/me/subscription" \
  -H "Authorization: Bearer <token>"