Hevn Inc User API
The User API from Hevn Inc — 21 operation(s) for user.
The User API from Hevn Inc — 21 operation(s) for user.
openapi: 3.1.0
info:
title: HEVN 2FA User API
description: Backend API for HEVN mobile neobank
version: 0.1.2
servers:
- url: https://api.hevn.finance
description: Production
tags:
- name: User
paths:
/api/v1/user/kyc:
put:
tags:
- User
summary: Create or get current user
description: Create or update user profile data for KYC.
operationId: update_user_kyc_data_api_v1_user_kyc_put
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UserCreateRequest'
required: true
responses:
'201':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/UserResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
security:
- HTTPBearer: []
/api/v1/user:
get:
tags:
- User
summary: Get current user
description: Get the profile of the currently authenticated user.
operationId: get_current_user_api_v1_user_get
security:
- HTTPBearer: []
parameters:
- name: device-id
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Device-Id
- name: device-type
in: header
required: false
schema:
type: string
default: ios
title: Device-Type
- name: device-name
in: header
required: false
schema:
type: string
default: ios
title: Device-Name
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/UserResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/kyc_link:
post:
tags:
- User
summary: Submit KYC data
description: Get Swipelux KYC verification link.
operationId: submit_kyc_api_v1_user_kyc_link_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/KycStatusResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/kyc/status:
get:
tags:
- User
summary: Get KYC status
description: Check the current KYC verification status. Use provider=align for Align.
operationId: get_kyc_status_api_v1_user_kyc_status_get
security:
- HTTPBearer: []
parameters:
- name: provider
in: query
required: false
schema:
$ref: '#/components/schemas/FiatProvider'
default: swipelux
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/KycStatusResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/geo:
get:
tags:
- User
summary: Geocode address
description: Search address via Google Maps Geocoding API and return structured address components.
operationId: geocode_address_api_v1_user_geo_get
security:
- HTTPBearer: []
parameters:
- name: query
in: query
required: true
schema:
type: string
title: Query
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/UserAddress'
title: Response Geocode Address Api V1 User Geo Get
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/event:
post:
tags:
- User
summary: Track user event
description: Proxy user events to Customer.io for analytics tracking.
operationId: track_user_event_api_v1_user_event_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/UserEventRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Track User Event Api V1 User Event Post
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/settings:
get:
tags:
- User
summary: Get user settings
operationId: get_user_settings_api_v1_user_settings_get
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/UserSettings-Output'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
put:
tags:
- User
summary: Update user settings
operationId: update_settings_api_v1_user_settings_put
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/UserSettings-Input'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/UserSettings-Output'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/bank_requested:
put:
tags:
- User
summary: Update requested bank rails
operationId: update_bank_requested_api_v1_user_bank_requested_put
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/BankRequestedSettings-Input'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/BankRequestedSettings-Output'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/notifications:
get:
tags:
- User
summary: Get recent notifications
description: Return recent notifications (email/push) for the current user.
operationId: get_notifications_api_v1_user_notifications_get
security:
- HTTPBearer: []
parameters:
- name: limit
in: query
required: false
schema:
type: integer
maximum: 200
minimum: 1
default: 50
title: Limit
- name: offset
in: query
required: false
schema:
type: integer
minimum: 0
default: 0
title: Offset
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/NotificationListResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/avatar:
post:
tags:
- User
summary: Upload user avatar
description: Upload avatar image to public storage and save URL to user profile.
operationId: upload_avatar_api_v1_user_avatar_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/AvatarUploadRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/AvatarUploadResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/share_kyb_link:
post:
tags:
- User
summary: Share KYB link
description: Send a KYB verification link to the specified email.
operationId: share_kyb_link_api_v1_user_share_kyb_link_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/ShareKybLinkRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Share Kyb Link Api V1 User Share Kyb Link Post
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/invite:
post:
tags:
- User
summary: Send invite
description: Legacy mapping for team invites. Prefer POST /team/invite.
operationId: send_legacy_user_invite_api_v1_user_invite_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/InviteRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Send Legacy User Invite Api V1 User Invite Post
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/contact/bank/validate:
post:
tags:
- User
summary: Prevalidate bank contact details
description: Validate bank identifiers before creating a contact.
operationId: validate_bank_contact_api_v1_user_contact_bank_validate_post
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/BankValidationRequest'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/BankValidationResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/contacts:
get:
tags:
- User
summary: Get user contacts
description: Get all contacts for the current user.
operationId: get_contacts_api_v1_user_contacts_get
security:
- HTTPBearer: []
parameters:
- name: limit
in: query
required: false
schema:
type: integer
maximum: 500
minimum: 1
default: 100
title: Limit
- name: offset
in: query
required: false
schema:
type: integer
minimum: 0
default: 0
title: Offset
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/ContactListResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/contact/preview:
get:
tags:
- User
summary: Preview contact by wallet or email
description: Look up a HEVN user by wallet address or email and return a preview.
operationId: preview_contact_api_v1_user_contact_preview_get
security:
- HTTPBearer: []
parameters:
- name: wallet
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: EVM wallet address
title: Wallet
description: EVM wallet address
- name: email
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Email address
title: Email
description: Email address
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/ContactPreviewResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/contact:
post:
tags:
- User
summary: Create contact
description: Create a new contact for the current user.
operationId: create_contact_api_v1_user_contact_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/ContactCreateRequest'
responses:
'201':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/contacts/{contact_id}:
patch:
tags:
- User
summary: Update contact name
description: Update safe contact metadata.
operationId: update_contact_api_v1_user_contacts__contact_id__patch
security:
- HTTPBearer: []
parameters:
- name: contact_id
in: path
required: true
schema:
type: string
format: uuid
title: Contact Id
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/ContactUpdateRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
delete:
tags:
- User
summary: Delete contact
description: Delete a contact.
operationId: delete_contact_api_v1_user_contacts__contact_id__delete
security:
- HTTPBearer: []
parameters:
- name: contact_id
in: path
required: true
schema:
type: string
format: uuid
title: Contact Id
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'204':
description: Successful Response
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/invite_code:
get:
tags:
- User
summary: Get invite code for current user
description: Get the current user's invite code, creating one if needed.
operationId: get_invite_code_api_v1_user_invite_code_get
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/InviteCodeResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/invited:
get:
tags:
- User
summary: Get users invited by current user
description: Return all users who joined via the current user's invite code.
operationId: get_invited_users_api_v1_user_invited_get
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/InvitedListResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/user/rewards:
get:
tags:
- User
summary: Get referral rewards earned by current user
description: Return list of referral rewards (KYB and volume bonuses) for the current user.
operationId: get_rewards_api_v1_user_rewards_get
security:
- HTTPBearer: []
parameters:
- name: limit
in: query
required: false
schema:
type: integer
maximum: 500
minimum: 1
default: 100
title: Limit
- name: cursor
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Reserved for future pagination
title: Cursor
description: Reserved for future pagination
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/RewardsListResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/kyb/user/share_kyb_link:
post:
tags:
- User
summary: Share KYB link
description: Send a KYB verification link to the specified email.
operationId: share_kyb_link_package_alias_api_v1_kyb_user_share_kyb_link_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/ShareKybLinkRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Share Kyb Link Package Alias Api V1 Kyb User Share Kyb Link Post
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
components:
schemas:
SwiftAccountInput:
properties:
accountHolderType:
$ref: '#/components/schemas/AlignAccountHolderType'
accountHolderFirstName:
anyOf:
- type: string
- type: 'null'
title: Accountholderfirstname
accountHolderLastName:
anyOf:
- type: string
- type: 'null'
title: Accountholderlastname
accountHolderBusinessName:
anyOf:
- type: string
- type: 'null'
title: Accountholderbusinessname
accountType:
type: string
const: swift
title: Accounttype
default: swift
bic:
type: string
title: Bic
bankName:
type: string
title: Bankname
accountNumber:
type: string
title: Accountnumber
country:
type: string
title: Country
currency:
type: string
title: Currency
default: USD
bankAddress:
anyOf:
- type: string
- type: 'null'
title: Bankaddress
routingNumber:
anyOf:
- type: string
- type: 'null'
title: Routingnumber
relationship:
anyOf:
- $ref: '#/components/schemas/app__schemas__base__ContactRelationship'
- type: 'null'
type: object
required:
- accountHolderType
- bic
- bankName
- accountNumber
- country
title: SwiftAccountInput
description: SWIFT bank contact input.
InviteVolumeBonus:
properties:
amount:
type: string
title: Amount
currency:
type: string
title: Currency
default: USD
threshold:
type: string
title: Threshold
type: object
required:
- amount
- threshold
title: InviteVolumeBonus
description: Volume-based bonus tier with a threshold.
UserSettings-Output:
properties:
appearance:
$ref: '#/components/schemas/AppearancePreference'
default: system
devMode:
type: boolean
title: Devmode
default: false
emailsTs:
additionalProperties:
type: string
type: object
title: Emailsts
notifications:
$ref: '#/components/schemas/NotificationsSettings'
bankRequested:
$ref: '#/components/schemas/BankRequestedSettings-Output'
type: object
title: UserSettings
description: User settings.
app__schemas__base__ContactRelationship:
type: string
enum:
- charity
- commercial_investment
- corporate_card
- credit_card
- dividend
- family
- financial_services
- good_sold
- goods_bought
- government
- insurance
- intergroup_transfer
- intra_group_dividends
- information_technology
- leasing
- loan_charges
- merchant_settlement
- mobile_wallet
- none
- non_resident_transfer_between_accounts
- pension
- personal_expenses
- prepaid_cards
- professional
- rental
- resident_transfer_between_accounts
- salaries
- telecommunications
- travel
- utility_bill
title: ContactRelationship
description: 'Unified contact relationship / transfer purpose.
Values match Align AlignTransferPurpose (the more granular set).
Mapped to Swipelux AccountHolderRelationship via ``swipelux_relationship``.'
UaeAccountInput:
properties:
accountHolderType:
$ref: '#/components/schemas/AlignAccountHolderType'
accountHolderFirstName:
anyOf:
- type: string
- type: 'null'
title: Accountholderfirstname
accountHolderLastName:
anyOf:
- type: string
- type: 'null'
title: Accountholderlastname
accountHolderBusinessName:
anyOf:
- type: string
- type: 'null'
title: Accountholderbusinessname
accountType:
type: string
const: uaefts
title: Accounttype
default: uaefts
bankName:
type: string
title: Bankname
currency:
type: string
title: Currency
default: AED
accountHolderAddress:
anyOf:
- $ref: '#/components/schemas/UserAddress'
- type: 'null'
ibanNumber:
type: string
title: Ibannumber
bic:
anyOf:
- type: string
- type: 'null'
title: Bic
relationship:
anyOf:
- $ref: '#/components/schemas/app__schemas__base__ContactRelationship'
- type: 'null'
type: object
required:
- accountHolderType
- bankName
- ibanNumber
title: UaeAccountInput
description: UAE FTS bank contact input.
InvitedStatus:
type: string
enum:
- invited
- kyb_pending
- verified
title: InvitedStatus
description: Status of an invited user along the KYB funnel.
InviteBonuses:
properties:
kyb:
$ref: '#/components/schemas/InviteBonus'
volume:
$ref: '#/components/schemas/InviteVolumeBonus'
type: object
required:
- kyb
- volume
title: InviteBonuses
description: Bonus configuration for the referral program.
BankRequestedSettings-Input:
properties:
rails:
$ref: '#/components/schemas/BankRequestedRails'
type: object
title: BankRequestedSettings
description: User bank-rail interest settings.
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
type: object
required:
- loc
- msg
- type
title: ValidationError
BankRequestedRails:
properties:
us:
$ref: '#/components/schemas/BankRequestedRailSettings'
swift:
$ref: '#/components/schemas/BankRequestedRailSettings'
eu:
$ref: '#/components/schemas/BankRequestedRailSettings'
uae:
$ref: '#/components/schemas/BankRequestedRailSettings'
type: object
title: BankRequestedRails
description: Rails the user is interested in opening.
ContactCreateRequest:
properties:
name:
type: string
maxLength: 200
minLength: 1
title: Name
default: ''
currency:
anyOf:
- type: string
maxLength: 4
minLength: 3
- type: 'null'
title: Currency
description: Currency override
email:
anyOf:
- type: string
- type: 'null'
title: Email
crypto:
anyOf:
- $ref: '#/components/schemas/ContactCryptoInput'
- type: 'null'
account:
anyOf:
- oneOf:
- $ref: '#/components/schemas/OnchainAccountInput'
- $ref: '#/components/schemas/EmailAccountInput'
- $ref: '#/components/schemas/SepaAccountInput'
- $ref: '#/components/schemas/SwiftAccountInput'
- $ref: '#/components/schemas/AchAccountInput'
- $ref: '#/components/schemas/UaeAccountInput'
- type: 'null'
title: Account
description: Account details
iban:
anyOf:
- $ref: '#/components/schemas/IBANAccountDetails-Input'
- $ref: '#/components/schemas/USExternalAccountDetails-Input'
- $ref: '#/components/schemas/SwiftAccountDetails-Input'
- type: 'null'
title: Iban
description: Bank account details in the same format as /banks ibanData
address:
anyOf:
- $ref: '#/components/schemas/UserAddress'
- type: 'null'
relationship:
$ref: '#/components/schemas/app__schemas__routers__user__contact__ContactRelationship'
default: external
type: ob
# --- truncated at 32 KB (76 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/hevn-inc/refs/heads/main/openapi/hevn-inc-user-api-openapi.yml