Skip to main content
EmaalCoin ties fiat legs and fees to stored pricing so operations stay auditable. Two building blocks work together:

Pricing Profiles (/api/v1/auth/pricing/profiles)

A pricing Profile describes how you charge (fees, spread behavior, settlement side) for a flow: You also set asset (typically USDT), optional network (tron or ethereum), optional fiat_currency when the profile is scoped to a corridor, and optional user_role for role-segmented pricing. fee_type is one of none, fixed, percentage, or hybrid, with BPS and min/max as needed.
Note: Creating and updating pricing profiles is admin-only (POST, GET, PUT, active flag endpoints).

FX Rate Quotes (/api/v1/auth/pricing/fx-quotes)

An FX Quote stores reference_rate and applied_rate (or derives applied rate from spread_bps) for a given flow, asset, and fiat_currency. Use expires_at so stale quotes fail validation when building snapshots. List and fetch by ID for audit. Use GET .../fx-quotes/active when you need the current active quote for a flow/asset/fiat (+ optional network).

Live Quote Tool (POST /api/v1/auth/pricing/quote)

Combines the active pricing profile and active FX for a hypothetical amount (amount_in + amount_in_type of fiat or crypto) - useful for admin dashboards and sanity checks before placing orders.

App Resolve (POST /api/v1/auth/pricing/resolve)

For app clients, use Resolve to get the correct pricing_profile_id and fx_rate_quote_id for the current flow context (flow/network/asset/fiat/amount), plus a computed commercial preview (fees and gross/net amounts) before creating the order. B2B OTC (bank deposit or withdrawal lanes with otc_type on profiles and FX quotes) uses POST /api/v1/auth/pricing/resolve-otc instead, so OTC pricing does not collide with generic b2b resolve. fiat_currency values in pricing resolve (including resolve-otc) must reference an active code from the shared fiat_currencies catalog. Use GET /api/v1/auth/fiat-currencies — the same endpoint other products use for fiat pickers. Example request
Example response

Linking to Orders and Transfers

When creating POST /api/v1/auth/orders or transfer endpoints, you pass:
  • pricing_profile_id
  • fx_rate_quote_id
together with amounts. The API builds a pricing snapshot (reference/applied rate, fees, net/gross lines) when both IDs are valid and consistent with order/transfer type, asset, fiat, and network rules. Partial pricing fields result in 400 - either supply all commercial fields required by the endpoint or omit pricing entirely where allowed. See also Orders and payments and Transfers (P2P and B2B).