API Reference

users

5 endpoints

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

Get User

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
avatar_image_file_urlstring | null
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

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
imageUrlstring

default: ""

namestring

default: ""

first_namestring

default: ""

last_namestring

default: ""

shortDescriptionstring

default: ""

longDescriptionstring

default: ""

callToActionCallToAction | null

object · CallToAction

FieldTypeDescription
type*enum
label*string
url*string
currentRoleCurrentRole | null

object · CurrentRole

FieldTypeDescription
title*string
company*string
customBackgroundCustomBackground | null

object · CustomBackground

FieldTypeDescription
backgroundstring | null
backgroundColorstring | null
backgroundImagestring | null
backgroundPositionstring | null
backgroundSizestring | null
backgroundRepeatstring | null
backgroundAttachmentstring | null
avatarFramestring | null
socialLinksProfileLink[]

array items · ProfileLink

FieldTypeDescription
label*string
url*string
linksProfileLink[]

array items · ProfileLink

FieldTypeDescription
label*string
url*string
longDescriptionContentobject[]
stickersobject[]
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

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

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

max_profilesinteger

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

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

max_profilesinteger

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>"