OpenApi Marketplace

Download OpenAPI specification:

Getting Started

Developer documentation for iJoin's partner integrations, written for engineers building server-to-server and embedded experiences:

  • Calculator API -- calculation endpoints for asset allocation, retirement forecasting, and portfolio modeling.
  • Embeddable Components -- drop-in <ijoin-embed> widgets (goal projection, social security calculator, managed account enrollment) for your own site.

Both areas authenticate with the same per-organization API key, and the steps below get you from zero to a working call in either one.

  1. Request credentials. iJoin issues an API key per advisory organization, per environment, during onboarding. Integrations using managed account providers get their provider IDs provisioned at the same time, and embed integrations also need their domains allowlisted by iJoin (contact your iJoin representative).
  2. Start in the sandbox. Develop and validate your integration against UAT first, then point at production.
Environment Base URL Notes
Production https://api.ijoin401k.com Live environment.
Sandbox (UAT) https://api.uat.ijoin401k.com Sandbox instance for testing in lower environments.

API keys are issued per environment: a sandbox key does not work against production and vice versa. All API endpoints return JSON; POST endpoints accept a JSON body (Content-Type: application/json), and GET endpoints take their inputs as query parameters.

  1. Make your first call. The fastest end-to-end check of your key and connectivity is a minimal pimco-igps calculation:
curl -X POST https://api.uat.ijoin401k.com/api/v3/calcs/pimco-igps \
  -H "X-API-Key: ${IJOIN_API_KEY}" \
  -H "Content-Type: application/json" \
  -d '{
    "birthDate": "1985-04-12",
    "desiredRetirementIncomeDate": "2050-05-01",
    "estimatedAnnualWages": 95000,
    "postTaxBalance": 0,
    "preTaxBalance": 25000,
    "preTaxDeferralPercent": 0.06,
    "rothDeferralPercent": 0.02
  }'

A 201 with an allocations array and a callId means your key and connectivity are working end to end.

  1. Go to production. Swap the base URL to https://api.ijoin401k.com and your production key. Nothing else changes.

API Key Lifecycle

Rule Detail
Expiration Every API key automatically expires 1 year after it is created. Requests made with an expired key return 401 Unauthorized.
Revocation Keys can be revoked at any time (contact iJoin or use your organization's admin tooling). A revoked key is rejected immediately.
Concurrent keys Your organization may hold up to 2 active keys at the same time. Creating a third key requires revoking one of the existing active keys first.
Rotation The second key slot exists so you can rotate with zero downtime: create a new key while the old one is still in use, deploy the new key to your services, then revoke the old key once nothing references it.

Plan key rotation ahead of the 1-year expiry so a forgotten key never takes your integration down: create the replacement key in the second slot, deploy it, then revoke the old one.

Health

Verify the health of iJoin services before or during an integration rollout. The health check authenticates with your X-API-Key and confirms connectivity to the API service and its backing services.

Service Health Check

Checks connectivity from the API service to its backing services (database and cache). Authenticate with your X-API-Key header. Returns 200 OK with status: "up" when every backing service is reachable, and 503 Service Unavailable with status: "down" when any is not. Use this endpoint to verify the health of iJoin services before or during an integration rollout.

Authorizations:
ApiKeyAuth

Responses

Request samples

curl https://api.ijoin401k.com/api/v3/marketplace/health

Response samples

Content type
application/json
{
  • "status": "up"
}

Authentication

All calculation endpoints authenticate with a single mechanism: an API key passed in the X-API-Key request header.

X-API-Key: <your-api-key>
  • Your API key is issued per organization by iJoin. Treat it as a secret: store it in your secret manager, send it only from server-side code, and never expose it in a browser, mobile app, or client-side bundle.
  • No token exchange is required. The API key on each request is the complete authentication story.
  • A missing or invalid key returns 401 Unauthorized. A key that is valid but not permitted for the requested resource returns 403 Forbidden.
{
  "error": "Unauthorized",
  "message": "API key is required",
  "statusCode": 401
}

Setting Up an AMA Provider

The iJoin AMA endpoint calculates against a managed account provider configured in the iJoin advisor portal. The provider supplies the model the engine runs, and the branding and disclosure content returned alongside every set of allocations, so it has to exist before the endpoint can answer.

Only a provider whose investment methodology is iJoin AMA Methodology can be used. A managedAccountProviderId that is unknown, that your API key is not entitled to, or that is configured with any other methodology all return a 404.

1. Open MAP Providers

In the advisor portal go to Settings › MAP Providers. The list shows every provider your organization has, with the investment methodology each one uses. Choose Add Provider.

The MAP Providers list in Settings, showing each provider and its investment methodology, with the Add Provider control

2. Name the provider and choose the methodology

Set a Provider Name, then set Investment Methodology to iJoin AMA Methodology. This is the choice that makes the provider usable from the AMA endpoint.

Upload Logo accepts a PNG, JPG or WEBP up to 1MB. Whatever you upload is returned as the fully qualified logoUri on every calculation, so callers can present your branding beside the allocations.

The Create Managed Account Provider dialog with Investment Methodology set to iJoin AMA Methodology

3. Fill in the display and disclosure content

Everything in Display & Disclosures is returned by the endpoint, so a caller can present the allocations with the disclosure material that has to accompany them:

Field Returned as
Display Name displayName
Phone displayPhoneNumber
Email displayEmail
ADV / Other Info Link advLink
Fee Disclosure Message feeDisclosure
Additional Disclosures additionalDisclosure
CONNECT Disclosures connectDisclosure

Model Key is required for this methodology. It selects the model the engine runs, and the endpoint takes it from the provider rather than from the request, so a calculation can never contradict what was configured here.

Set Enabled for use to Yes when the provider is ready. Then save.

The Create Managed Account Provider dialog scrolled to Display & Disclosures, Model Key and Enabled for use

4. Copy the provider id

Every request to the AMA endpoint carries the provider's id as managedAccountProviderId. There are two ways to get it.

From the MAP Providers list, open the row's action menu and choose Copy Provider ID.

The MAP Providers row action menu open, showing Edit, Copy Provider ID and Delete

Or reopen the provider for editing, where the id is shown at the top with a copy control beside it. It appears only when editing, since a provider has no id until it is saved.

The Edit Managed Account Provider dialog showing the Provider ID with a copy control

Conventions

Convention Detail
callId Every calculation response includes a unique callId, and error responses include it too whenever the calculation was reached. Treat the callId as your support reference id: quote it whenever you contact iJoin support about a calculation, as it lets iJoin trace the exact execution and diagnose the issue immediately. Log it for every call.
Dates All date fields are strings in strict YYYY-MM-DD format. Any other format is rejected with a 400 validation error.
Numbers Rates and percentages are fractions between 0 and 1 (0.06 means 6%). Employer match amounts are ratios on the same scale (0.5 matches 50 cents per dollar), as are the category allocations you submit and the fund allocations returned, each of which sums to 1. Dollar fields are plain dollar amounts.
Rate limiting Requests are throttled per caller. Handle 429 Too Many Requests with exponential backoff.
Required vs Optional Required fields are marked as such in each request schema. Omitting a required field returns a 400 validation error; defaults are noted where they apply.
Tracing You may send an x-request-id header with any request; iJoin adopts it as the trace id and propagates it through calculation tracing end to end. Every response echoes the id back in the x-request-id response header (iJoin generates one when you do not send it). When contacting support, the response callId is your reference id; include your request id alongside it if you set one.
Validation errors Invalid requests (body or query parameters) return 400 with a message array listing every failed constraint (see Error Reference).

Calculations

The calculation endpoints. Authenticate via X-API-Key; every response returns a callId to quote in any support request.

Goal Projection

Performs baseline retirement goal calculations and shortfall analysis for plans using a Managed Account Provider (MAP).

All inputs are passed as query parameters. retirementData in the response continues through the participant's full projected retirement horizon.

Authorizations:
ApiKeyAuth
query Parameters
birthDate
required
string^\d{4}-\d{2}-\d{2}$
Example: birthDate=1985-04-12

Participant's date of birth (YYYY-MM-DD).

desiredRetirementIncomeAmount
number
Example: desiredRetirementIncomeAmount=76000

Annual income target during retirement.

desiredRetirementIncomeDate
required
string^\d{4}-\d{2}-\d{2}$
Example: desiredRetirementIncomeDate=2050-05-01

Target retirement commencement date (YYYY-MM-DD).

erMatchTier1DeferralRate
number [ 0 .. 0.15 ]
Example: erMatchTier1DeferralRate=0.03

Tier 1: deferral percentage the tier matches up to.

erMatchTier1MatchingAmount
number [ 0 .. 5 ]
Example: erMatchTier1MatchingAmount=1

Tier 1: match ratio within the tier (1 = dollar for dollar, 0.5 = 50 cents per dollar).

erMatchTier2DeferralRate
number [ 0 .. 0.15 ]
Example: erMatchTier2DeferralRate=0.05

Tier 2 deferral ceiling.

erMatchTier2MatchingAmount
number [ 0 .. 5 ]
Example: erMatchTier2MatchingAmount=0.5

Tier 2 match ratio.

erMatchTier3DeferralRate
number [ 0 .. 0.15 ]

Tier 3 deferral ceiling.

erMatchTier3MatchingAmount
number [ 0 .. 5 ]

Tier 3 match ratio.

erMatchTier4DeferralRate
number [ 0 .. 0.15 ]

Tier 4 deferral ceiling.

erMatchTier4MatchingAmount
number [ 0 .. 5 ]

Tier 4 match ratio.

erMatchTier5DeferralRate
number [ 0 .. 0.15 ]

Tier 5 deferral ceiling.

erMatchTier5MatchingAmount
number [ 0 .. 5 ]

Tier 5 match ratio.

erOtherFlatDollarAmount
number >= 0

Non-matching employer contribution, flat dollars per year.

erOtherPercentOfCompensation
number [ 0 .. 0.25 ]
Example: erOtherPercentOfCompensation=0.01

Non-matching employer contribution as a percent of compensation.

estimatedAnnualWages
required
number >= 0
Example: estimatedAnnualWages=95000

Current annualized salary.

gender
string
Enum: "M" "F"
Example: gender=F

Participant gender.

inflation
number

Custom annual inflation rate assumption.

nqdcDeferralDollars
number

Non-qualified deferred compensation deferral dollars.

nqdcDeferralPercent
number [ 0 .. 1 ]

Non-qualified deferred compensation deferral percent.

otherPensionMonth
number

Monthly income from an external pension.

otherPostTaxBalances
number >= 0

Post-tax balances held outside the employer plan.

otherPreTaxBalances
number >= 0
Example: otherPreTaxBalances=45000

Pre-tax balances held outside the employer plan.

otherRothBalances
number >= 0

Roth balances held outside the employer plan.

percentOrDollar
string
Enum: "Dollar" "Percent"
Example: percentOrDollar=Percent

Whether deferrals are expressed as Percent or Dollar.

postTaxBalance
required
number >= 0
Default: 0

Current post-tax plan balance. Defaults to 0.

postTaxDeferralDollars
number

Post-tax deferral as a flat dollar amount per pay period.

postTaxDeferralPercent
number [ 0 .. 1 ]

Post-tax deferral as a percent of wages.

preTaxBalance
required
number >= 0
Default: 0
Example: preTaxBalance=120000

Current pre-tax plan balance. Defaults to 0.

preTaxDeferralDollars
number

Pre-tax deferral as a flat dollar amount per pay period.

preTaxDeferralDollarsCatchup
number >= 0

Pre-tax catch-up deferral dollars per pay period.

preTaxDeferralDollarsFrequency
number
Enum: 52 26 24 12

Pay periods per year for dollar deferrals (e.g. 26).

preTaxDeferralPercent
number [ 0 .. 1 ]
Example: preTaxDeferralPercent=0.06

Pre-tax deferral as a percent of wages.

preTaxDeferralPercentCatchup
number [ 0 .. 1 ]

Pre-tax catch-up deferral percent.

rorDiy
number

Expected annual rate of return driving the projection.

rothBalance
number >= 0
Example: rothBalance=15000

Current Roth balance in the plan.

rothDeferralDollars
number

Roth deferral as a flat dollar amount per pay period.

rothDeferralDollarsCatchup
number >= 0

Roth catch-up deferral dollars per pay period.

rothDeferralDollarsFrequency
number
Enum: 52 26 24 12

Pay periods per year for Roth dollar deferrals.

rothDeferralPercent
number [ 0 .. 1 ]
Example: rothDeferralPercent=0.02

Roth deferral as a percent of wages.

rothDeferralPercentCatchup
number [ 0 .. 1 ]

Roth catch-up deferral percent.

Responses

Request samples

curl "https://api.ijoin401k.com/api/v3/calcs/goal-projection?birthDate=1985-04-12&desiredRetirementIncomeAmount=76000&desiredRetirementIncomeDate=2050-05-01&erMatchTier1DeferralRate=0.03&erMatchTier1MatchingAmount=1&erMatchTier2DeferralRate=0.05&erMatchTier2MatchingAmount=0.5&erOtherPercentOfCompensation=0.01&estimatedAnnualWages=95000&gender=F&otherPreTaxBalances=45000&percentOrDollar=Percent&postTaxBalance=0&preTaxBalance=120000&preTaxDeferralPercent=0.06&rothBalance=15000&rothDeferralPercent=0.02" \
  -H "X-API-Key: ${IJOIN_API_KEY}"

Response samples

Content type
application/json
{
  • "callId": "7b3f9d21-6c48-4a0e-b5d7-2e9f8c4a1d06",
  • "currentEstimate": 1148392.55,
  • "retirementData": [
    ],
  • "riskProfile": "Moderate",
  • "shortfall": 0,
  • "totalProjGoalCompletionAtRet": 104.2,
  • "totalProjMnthlyERplanAtRet": 3822.15,
  • "totalProjMnthlyIncomeAtRet": 6598.41,
  • "totalProjMnthlyNeedAtRet": 6333.33,
  • "totalProjMnthlyOtherInvAtRet": 325,
  • "totalProjMnthlySocSecAtRet": 2451.26
}

Personal Rate of Return

Calculates a personal rate of return (PRR) over a period using a money-weighted, annualized method that accounts for the timing and size of every cash flow.

Supply beginningBalance, endingBalance, and the cashFlows that occurred between them, and the return is computed entirely from the values you pass. Each cash flow amount is negative for a contribution (money paid in) and positive for a withdrawal (money taken out). Omit cashFlows when there was no activity between the two balances.

When startDate is omitted it defaults to the earliest cash flow; when endDate is omitted it defaults to today.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
beginningBalance
required
number

Portfolio value at the start of the measurement period.

Array of objects (CashFlowDto) <= 5000 items

Dated contributions and withdrawals over the period. A contribution is a negative amount; a withdrawal is a positive amount. Omit or pass an empty array when there was no activity between the two balances.

endDate
string^\d{4}-\d{2}-\d{2}$

End of the measurement period (YYYY-MM-DD). Defaults to today when omitted.

endingBalance
required
number

Portfolio value at the end of the measurement period.

startDate
string^\d{4}-\d{2}-\d{2}$

Start of the measurement period (YYYY-MM-DD). Defaults to the date of the earliest cash flow when omitted.

Responses

Request samples

Content type
application/json
{
  • "beginningBalance": 120000,
  • "cashFlows": [
    ],
  • "endDate": "2025-06-30",
  • "endingBalance": 148392.55,
  • "startDate": "2024-01-01"
}

Response samples

Content type
application/json
{
  • "annualizedReturn": 0.0842,
  • "beginningBalance": 120000,
  • "endingBalance": 148392.55,
  • "growthMultiple": 1.2366,
  • "investmentGain": 16392.55,
  • "netContributions": 12000,
  • "periodYears": 1.5,
  • "prr": 0.0842,
  • "totalContributions": 12000,
  • "totalFees": 0,
  • "totalWithdrawals": 0
}

Advice Engines

Advice engine endpoints that generate asset allocations and fund selections for a participant. Authenticate via X-API-Key; every response returns a callId to quote in any support request.

iJoin AMA

Generates asset allocations for a participant’s risk profile across the submitted fund lineup, and returns the disclosure material that must accompany them.

Every request identifies the provider by managedAccountProviderId. The provider's ADV / other information link, logo and disclosures are returned alongside the allocations so they can be presented together.

The provider must be configured with the iJoin AMA methodology. A managedAccountProviderId that is unknown, that your API key is not entitled to, or that is configured with any other methodology all return a 404.

The model is taken from the provider's configuration, so there is no modelKey on this request.

Each fund is identified by its cusip, and every returned allocation echoes the cusip of the matching submitted fund. Supply allocations to steer the result toward category-level targets. Each category is a Morningstar category name (Large Blend, Intermediate Core Bond), not a broad asset-class label, and each allocation is a decimal between 0 and 1 with the set summing to 1. A category the engine cannot map, or one no submitted fund belongs to, is reported back in messages. When none of the submitted funds can be allocated (for example, unrecognized CUSIPs), the request returns a 422 carrying the callId to quote in any support request and a messages array explaining what could not be allocated.

Don't know the participant's risk profile? Call the Goal Projection endpoint first and use the riskProfile from its response to select the riskProfile value here.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
Array of objects (LeafHouseAllocationDto)

Category-level allocation targets to map from an external allocation.

birthDate
required
string

Participant's date of birth (YYYY-MM-DD). The engine resolves each model's variant by participant age, so it is required.

required
Array of objects (LeafHouseFundDto) non-empty

Fund universe to allocate across. Must contain at least one fund.

managedAccountProviderId
required
string\S+

Managed account provider requesting the calculation. Must be a provider your organization is entitled to that is configured with the iJoin AMA methodology; anything else returns a 404. The provider's configured model drives the calculation, so no model is accepted here.

riskProfile
required
string
Enum: "Agg" "Con" "Mod" "ModAgg" "ModCon"

Participant risk profile tier.

submodel
string^EP\d+$

Franklin Templeton GOE submodel (e.g. EP1). Only used when the provider is configured with the FKGOE1 model, which resolves age profiles per submodel; defaults to EP1.

Responses

Request samples

Content type
application/json
{
  • "allocations": [
    ],
  • "birthDate": "1985-04-12",
  • "funds": [
    ],
  • "managedAccountProviderId": "51754dce-65e0-4d63-8ec9-acff9fd4b9a9",
  • "riskProfile": "ModAgg"
}

Response samples

Content type
application/json
{
  • "additionalDisclosure": "Registration does not imply a certain level of skill or training.",
  • "allocations": [
    ],
  • "callId": "string",
  • "connectDisclosure": "LeafHouse is a registered investment advisor.",
  • "displayEmail": "service@leafhousefinancial.com",
  • "displayName": "LeafHouse Financial",
  • "displayPhoneNumber": "+15125551234",
  • "feeDisclosure": "An annual advisory fee of 0.35% is deducted quarterly.",
  • "messages": [
    ]
}

LeafHouse

Generates asset allocations and fund selections for a participant's risk profile and chosen model via the LeafHouse engine.

Each fund is identified by its cusip, and every returned allocation echoes the cusip of the matching submitted fund. When none of the submitted funds can be allocated (for example, unrecognized CUSIPs), the request returns a 422 carrying the callId to quote in any support request and a messages array explaining what could not be allocated.

birthDate is required: the engine resolves its models by the participant's age, so the participant's date of birth must be supplied. Age also drives fund selection directly — CPGTD1 allocates to the target-date fund matching the participant's projected retirement year, so the submitted lineup must include those funds.

Supply allocations to steer the result toward category-level targets. Each category is a Morningstar category name (Large Blend, Intermediate Core Bond), not a broad asset-class label, and each allocation is a decimal between 0 and 1 with the set summing to 1. A category the engine cannot map, or one no submitted fund belongs to, is reported back in messages.

FKGOE1 resolves its age profiles per submodel; the optional submodel (e.g. EP1, the default) is only used with this model key.

Don't know the participant's risk profile? Call the Goal Projection endpoint first and use the riskProfile from its response to select the riskProfile value here.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
Array of objects (LeafHouseAllocationDto)

Category-level allocation targets to map from an external allocation.

birthDate
required
string

Participant's date of birth (YYYY-MM-DD). The engine resolves each model's variant by participant age, so it is required.

required
Array of objects (LeafHouseFundDto) non-empty

Fund universe to allocate across. Must contain at least one fund.

modelKey
string
Default: "IJN001"
Enum Description
BLKRK1

BlackRock models.

CPGTD1

Capital Group target-date models.

FKGOE1

Franklin Templeton Goals Optimization Engine (GOE) models.

IJN001

iJoin native models (default).

Model identifier. Defaults to IJN001.

riskProfile
required
string
Enum Description
Agg

Aggressive.

Con

Conservative.

Mod

Moderate.

ModAgg

Moderately aggressive.

ModCon

Moderately conservative.

Participant risk profile tier.

submodel
string^EP\d+$

Franklin Templeton GOE submodel (e.g. EP1). Only used with modelKey FKGOE1, which resolves age profiles per submodel; defaults to EP1 when omitted.

Responses

Request samples

Content type
application/json
{
  • "allocations": [
    ],
  • "birthDate": "1985-04-12",
  • "funds": [
    ],
  • "modelKey": "IJN001",
  • "riskProfile": "ModAgg"
}

Response samples

Content type
application/json
{
  • "additionalDisclosure": "Allocations are provided by LeafHouse Financial Advisors, LLC and are for illustrative purposes only. Past performance does not guarantee future results.",
  • "allocations": [
    ],
  • "callId": "c1d9e7a4-3f52-48b6-9e0d-7a2b4c8f1e63",
  • "messages": [
    ]
}

PIMCO IGPS

Produces optimized asset allocations and custom target-date tracks using PIMCO's Income-Guided Personalized Solutions (IGPS) methodology.

Deferral pairs: provide exactly one of preTaxDeferralDollars or preTaxDeferralPercent, and exactly one of rothDeferralDollars or rothDeferralPercent. Sending both values of a pair, or neither, returns a 400 validation error.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
birthDate
required
string^\d{4}-\d{2}-\d{2}$

Participant's date of birth (YYYY-MM-DD).

desiredRetirementIncomeAmount
number

Desired annual distribution target.

desiredRetirementIncomeDate
required
string^\d{4}-\d{2}-\d{2}$

Planned retirement target date (YYYY-MM-DD).

erMatchTier1DeferralRate
number [ 0 .. 0.15 ]

Tier 1: deferral percentage the tier matches up to.

erMatchTier1MatchingAmount
number [ 0 .. 5 ]

Tier 1: match ratio within the tier (1 = dollar for dollar, 0.5 = 50 cents per dollar).

erMatchTier2DeferralRate
number [ 0 .. 0.15 ]

Tier 2 deferral ceiling.

erMatchTier2MatchingAmount
number [ 0 .. 5 ]

Tier 2 match ratio.

erMatchTier3DeferralRate
number [ 0 .. 0.15 ]

Tier 3 deferral ceiling.

erMatchTier3MatchingAmount
number [ 0 .. 5 ]

Tier 3 match ratio.

erMatchTier4DeferralRate
number [ 0 .. 0.15 ]

Tier 4 deferral ceiling.

erMatchTier4MatchingAmount
number [ 0 .. 5 ]

Tier 4 match ratio.

erMatchTier5DeferralRate
number [ 0 .. 0.15 ]

Tier 5 deferral ceiling.

erMatchTier5MatchingAmount
number [ 0 .. 5 ]

Tier 5 match ratio.

erOtherFlatDollarAmount
number >= 0

Non-matching employer contribution, flat dollars per year.

erOtherPercentOfCompensation
number [ 0 .. 0.25 ]

Non-matching employer contribution as a percent of compensation.

estimatedAnnualWages
required
number >= 0

Current annual base wages.

inflation
number

Inflation assumption modifier.

nqdcDeferralDollars
number

Non-qualified deferred compensation deferral dollars.

nqdcDeferralPercent
number [ 0 .. 1 ]

Non-qualified deferred compensation deferral percent.

percentOrDollar
string
Enum: "Dollar" "Percent"

Whether deferrals are expressed as Percent or Dollar.

postTaxBalance
required
number >= 0
Default: 0

Current post-tax portfolio balance. Defaults to 0.

postTaxDeferralDollars
number

Post-tax deferral dollars per pay period.

postTaxDeferralPercent
number [ 0 .. 1 ]

Post-tax deferral percent.

preTaxBalance
required
number >= 0
Default: 0

Current pre-tax portfolio balance. Defaults to 0.

preTaxDeferralDollars
number

Pre-tax deferral dollars per pay period. Mutually exclusive with preTaxDeferralPercent.

preTaxDeferralDollarsCatchup
number >= 0

Pre-tax catch-up deferral dollars per pay period.

preTaxDeferralDollarsFrequency
number
Enum: 52 26 24 12

Pay periods per year for dollar deferrals.

preTaxDeferralPercent
number [ 0 .. 1 ]

Pre-tax deferral percent. Mutually exclusive with preTaxDeferralDollars.

preTaxDeferralPercentCatchup
number [ 0 .. 1 ]

Pre-tax catch-up deferral percent.

rbprRetirement
number

PIMCO IGPS risk parameter (risk-based personalization at retirement).

reprRetirement
number

PIMCO IGPS return parameter (return expectation at retirement).

rothDeferralDollars
number

Roth deferral dollars per pay period. Mutually exclusive with rothDeferralPercent.

rothDeferralDollarsCatchup
number >= 0

Roth catch-up deferral dollars per pay period.

rothDeferralDollarsFrequency
number
Enum: 52 26 24 12

Pay periods per year for Roth dollar deferrals.

rothDeferralPercent
number [ 0 .. 1 ]

Roth deferral percent. Mutually exclusive with rothDeferralDollars.

rothDeferralPercentCatchup
number [ 0 .. 1 ]

Roth catch-up deferral percent.

Responses

Request samples

Content type
application/json
{
  • "birthDate": "1990-02-27",
  • "desiredRetirementIncomeAmount": 54400,
  • "desiredRetirementIncomeDate": "2057-03-01",
  • "erMatchTier1DeferralRate": 0.05,
  • "erMatchTier1MatchingAmount": 0.5,
  • "estimatedAnnualWages": 68000,
  • "percentOrDollar": "Percent",
  • "postTaxBalance": 0,
  • "preTaxBalance": 42000,
  • "preTaxDeferralPercent": 0.05,
  • "rothDeferralPercent": 0.03
}

Response samples

Content type
application/json
{
  • "additionalDisclosure": "PIMCO Income-Guided Personalized Solutions allocations are based on the inputs provided and are not individualized investment advice.",
  • "allocations": [
    ],
  • "callId": "a9c2f5e8-1b74-4d30-96a5-8e3b6d0c7f21",
  • "description": "IGPS glide path allocation for a participant 31 years from the target retirement date, income-guided toward a $54,400 annual distribution target.",
}

Error Reference

Status Meaning Typical cause
400 Bad Request Request failed validation (body or query parameters); message lists each failed constraint.
401 Unauthorized Missing, malformed, expired, or revoked API key.
403 Forbidden API key is valid but is not permitted to call this endpoint.
404 Not Found The requested resource does not exist.
422 Unprocessable Entity The request was valid, but the calculation could not produce a valid result for the provided inputs (e.g. values that lead to an impossible projection, such as an annual wage of 0). The response includes the callId of the failed calculation; quote it as your reference id when contacting support. Adjust the inputs rather than retrying unchanged.
429 Too Many Requests Rate limit exceeded; retry with exponential backoff.
500 Internal Server Error Unexpected failure; retry once, then contact support with the callId or request timestamp.

Validation error example:

{
  "error": "BadRequest",
  "message": [
    "birthDate must be in YYYY-MM-DD format",
    "risk must be one of the following values: Con, ModCon, Mod, ModAgg, Agg"
  ],
  "statusCode": 400
}

Calculation error example (422); the callId is your support reference id for the failed calculation:

{
  "callId": "395262fa-d014-4632-b6ad-d89cb113359d",
  "error": "UnprocessableEntity",
  "message": "the calculation could not produce a valid result for the provided inputs",
  "statusCode": 422
}

Quick Start

Add iJoin's embeddable widgets -- the retirement goal projection, the social security calculator, and the managed account enrollment and post-enrollment widgets -- to your site. Two integrations are available and both render the same widgets: a framework-agnostic Web Component (<ijoin-embed>) and a dependency-free React component for React 18+.

Domain allowlisting required. Widgets only render on domains iJoin has allowlisted for your organization -- on any other domain the iframe will not load. Request allowlisting for every domain you embed on, including staging hosts, through your iJoin representative before integrating.

How it works

The participant data a widget renders never travels through the browser. Your backend submits it to iJoin when requesting a token, and the page only ever handles that opaque token:

your backend ── POST /embed/token { embedType, data } ──▶ iJoin
     │                             (stores data, returns token)
     ▼
your page ── <ijoin-embed type token> ──▶ sandboxed iframe
             (widget rendered by iJoin from the stored data)
  1. Server-side: your backend calls the token endpoint with your API key, the embedType, and that widget's data payload (see Widgets). iJoin stores the payload and returns a token that expires after 1 hour.
  2. Client-side: your page renders the component (Web Component or React) with the token. The component creates a sandboxed iframe that loads the widget UI from iJoin; the token authorizes the session and connects it to the stored data.
  3. While embedded: the widget sizes itself automatically, reports user actions as events, and accepts a fresh token at any time to extend the session without reloading.

1. Get an embed token (server-side)

Your backend calls the Create Embed Token endpoint with your API key. Never expose your API key in client-side code. The embedType in the request determines which widget the token is for and the shape of its data payload; see Widgets for what each widget does and expects, and the endpoint reference for the full schemas.

Hold on to the returned token value -- you'll pass it to the front end.

2. Choose your integration

  • React -- a small component with typed props and callback-based events, shipped without any bundled dependencies (React 18+ is a peer).
  • Web Component -- one <script> tag registers <ijoin-embed> globally; works with any (or no) framework.

Both integrations take the same inputs (base-url/baseUrl, type, token) and will not render until all three are present. The type must match the embedType used when requesting the token: goal-projection, managed-account, post-enrollment-managed, or social-security-calculator.

Embed Token

Server-side token exchange for the <ijoin-embed> widgets. Authenticate with your X-API-Key; the returned JWT drives one widget session.

Create Embed Token

Exchanges your API key and a widget payload for a short-lived embed token. Call this endpoint from your backend only and pass the returned token to the <ijoin-embed> element on your page; never expose your API key in client-side code.

The embedType field determines the shape of data (see the schema below). Tokens expire after 1 hour; the response expiresAt tells you when. Setting a fresh token attribute on the element updates the existing session without a full reload.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
required
any

Shape depends on embedType: GoalProjectionData for goal-projection, ManagedAccountData for managed-account, PostEnrollmentManagedData for post-enrollment-managed, SocialSecurityCalculatorData for social-security-calculator.

embedType
required
string
Enum: "goal-projection" "managed-account" "post-enrollment-managed" "social-security-calculator"

Responses

Request samples

Content type
application/json
Example
{
  • "data": {
    },
  • "embedType": "goal-projection"
}

Response samples

Content type
application/json
{
  • "expiresAt": "2025-07-01T13:00:00.000Z",
  • "token": "eyJhbGciOiJIUzI1NiIs..."
}

Content Security Policy

If your site sets a CSP header, add the following directives (both integrations load the widget in an iframe from the iJoin host; the Web Component additionally loads its script from it):

script-src https://api.ijoin401k.com;
frame-src https://api.ijoin401k.com;

Widgets

Four widgets are available. Everything on this page describes the server-side token request: the embedType your backend sends to Create Embed Token selects the widget (the component's type must match it), and it determines the shape of the data payload submitted alongside it. None of these fields are passed to the component in the browser -- the component only receives the resulting token, and iJoin renders the widget from the data stored with it. The field tables below are generated from the same schemas that validate your requests.

Goal projection

goal-projection renders an interactive retirement goal projection: projected income at retirement versus the participant's goal, contribution modeling, and shortfall analysis, computed from the demographic and account data you supply. dateOfBirth and socialSecurityNumber identify the participant and are required; planId, planType, annualSalary, and the balance/contribution fields shape the projection, with defaults applied where marked.

Token request data fields

Field Type Required Default Description
annualMatchLimitAmount number No
annualSalary number No
autoEnrollment boolean No false
autoIncreasePreTaxAnnualPercent number No
autoIncreasePreTaxMaximumPercent number No
autoIncreaseRothAnnualPercent number No
autoIncreaseRothMaximumPercent number No
combinedContributionMax number No
contributionRetirementAge number No
dateOfBirth string Yes
dateOfHire string No
employeeAutoIncreaseAllowed boolean No
employeeMaximumContributionLimit number No
employerMatchBalance number No 0
employerMatchingContributionYtdDollars number No 0
employerOtherBalance number No 0
employerOtherContributionYtdDollars number No 0
gender string No Allowed: F, M.
isCatchupContributionAllowed boolean No
isRothCatchupContributionAllowed boolean No
maritalStatus string No "S" Allowed: M, S.
matchTiers EmbedMatchTier[] No
monthlySavingsNeededAtRetirement number No
nqdcDeferralPercent number No 0
nqdcDeferralYtdDollars number No 0
otherEmployerContributionDollars number No 0
otherEmployerContributionPercent number No 0
outsideMonthlyPension number No 0
outsidePostTax number No 0
outsidePreTax number No 0
outsideRoth number No 0
payPeriodsPerYear number No 26
planId string No
planType string No Allowed: 401k, 401k plan, 401k plan with roth, 401k-roth, 403b, 403(b), … 12 more (see the endpoint schema).
postTaxBalance number No 0
postTaxContributionMax number No
postTaxDeferralYtdDollars number No 0
preTaxAutoIncreaseFrequency string No
preTaxBalance number No 0
preTaxContribution number No 0
preTaxContributionMax number No
preTaxDeferralCatchupPercent number No
preTaxDeferralYtd number No
preTaxDeferralYtdCatchupDollars number No
retirementAge number No
rolloverBalance number No 0
rothAutoIncreaseMax number No
rothAutoIncreasePercent number No
rothBalance number No 0
rothContribution number No 0
rothContributionMax number No
rothDeferralCatchupPercent number No
rothDeferralYtdCatchupDollars number No 0
rothDeferralYtdDollars number No 0
rothTaxAutoIncreaseFrequency string No
socialSecurityNumber string Yes
stateOfResidency string No Allowed: AK, AL, AR, AZ, CA, CO, … 45 more (see the endpoint schema).
stateOfRetirement string No "TX" Allowed: AK, AL, AR, AZ, CA, CO, … 45 more (see the endpoint schema).

matchTiers entries describe the employer match design:

Field Type Required Default Description
employeeContributionAmount number No
sponsorContributionAmount number No
tierLevel number No

Token request example

{
  "data": {
    "annualSalary": 95000,
    "dateOfBirth": "1970-01-15",
    "dateOfHire": "2005-06-01",
    "employerMatchingContributionYtdDollars": 2850,
    "gender": "M",
    "maritalStatus": "M",
    "matchTiers": [
      {
        "employeeContributionAmount": 3,
        "sponsorContributionAmount": 100,
        "tierLevel": 1
      },
      {
        "employeeContributionAmount": 2,
        "sponsorContributionAmount": 50,
        "tierLevel": 2
      }
    ],
    "outsidePreTax": 32000,
    "outsideRoth": 18500,
    "payPeriodsPerYear": 26,
    "planId": "132051",
    "planType": "401k plan",
    "postTaxBalance": 0,
    "preTaxBalance": 125000,
    "preTaxContribution": 6,
    "preTaxContributionMax": 100,
    "retirementAge": 65,
    "rolloverBalance": 15000,
    "rothBalance": 45000,
    "rothContribution": 4,
    "rothContributionMax": 100,
    "socialSecurityNumber": "987654321",
    "stateOfResidency": "CA",
    "stateOfRetirement": "CA"
  },
  "embedType": "goal-projection"
}

Managed account

managed-account displays MAP-provider-specific enrollment content for a plan as a single step: a provider overview (About Our Managed Solution) with a View Associated Disclosures link that reveals the disclosure list and a single agreement checkbox in place, without navigating away from the step. All fields are optional; planId associates the session with a plan, and iJoin renders the managed account program content and disclosures configured for your organization server-side.

Token request data fields

Field Type Required Default Description
planId string No

Token request example

{
  "data": {
    "planId": "132051"
  },
  "embedType": "managed-account"
}

Events

Whenever the participant toggles the disclosures agreement checkbox, the widget raises an event with the current checked state (true when the participant has agreed, false when they clear it) so your page can gate document delivery on the participant's consent.

Web Component (action event with detail.action of managed-account-agreement-changed; detail.accepted carries the state):

const embed = document.querySelector('ijoin-embed');
embed.addEventListener('action', event => {
  if (event.detail.action === 'managed-account-agreement-changed') {
    documentDeliveryButton.disabled = !event.detail.accepted;
  }
});

React (dedicated callback prop):

<IJoinEmbed
  onAgreementChanged={setDocumentDeliveryEnabled}
  {...otherProps}
/>

Post-enrollment managed

post-enrollment-managed displays managed account content for a participant after they have completed enrollment. As with the enrollment widget, all fields are optional; planId associates the session with a plan, and iJoin renders the content configured for your organization server-side.

Token request data fields

Field Type Required Default Description
planId string No

Token request example

{
  "data": {
    "planId": "132051"
  },
  "embedType": "post-enrollment-managed"
}

Social security calculator

social-security-calculator renders an interactive social security benefit calculator. All fields are optional; providing planId and socialSecurityNumber lets iJoin look up the participant's record to seed the calculation, and the participant can adjust the retirement age and wage assumptions inside the widget either way.

Token request data fields

Field Type Required Default Description
planId string No
socialSecurityNumber string No

Token request example

{
  "data": {
    "planId": "132051",
    "socialSecurityNumber": "987654321"
  },
  "embedType": "social-security-calculator"
}

React

A dedicated React component for React 18+, with typed props and callback-based events. It ships as a single ES module with no bundled dependencies: react and react/jsx-runtime are imported from your application, so it adds ~1.3 kB (gzipped) to your bundle.

Install

The component is published as an npm package tarball at a stable URL. Add it to your package.json like any other dependency:

{
  "dependencies": {
    "@ijoin/embed-react": "https://api.ijoin401k.com/embed/ijoin-embed-react.tgz"
  }
}

Or install it from the command line with your package manager of choice; each resolves the tarball URL, records it in your lockfile, and exposes the package as @ijoin/embed-react:

npm

npm install https://api.ijoin401k.com/embed/ijoin-embed-react.tgz

Yarn

yarn add @ijoin/embed-react@https://api.ijoin401k.com/embed/ijoin-embed-react.tgz

pnpm

pnpm add https://api.ijoin401k.com/embed/ijoin-embed-react.tgz

To pick up a newer release, remove and re-add the dependency; a plain npm update cannot detect changes behind a static URL, and the lockfile's integrity pin blocks in-place changes (see the warning below).

The tarball is integrity-pinned by your lockfile. npm, Yarn, and pnpm all record a SHA-512 hash of the downloaded tarball on first install (the package.json and command-line installs above pin it the same way). When iJoin publishes a new version at this URL, existing installs fail with an integrity error (npm EINTEGRITY, Yarn YN0018, pnpm ERR_PNPM_TARBALL_INTEGRITY) rather than silently updating -- typically surfacing in CI first, while machines with a warm cache keep installing the old version. When that happens, re-resolve the dependency: remove and re-add it, or delete its lockfile entry and reinstall. We plan to publish versioned tarball URLs in a future release so each version keeps a stable hash and upgrades become explicit. Until then, you can avoid the lockfile pin entirely by vendoring the raw module and its type declarations into your project (see the curl downloads below).

If you prefer to vendor the source instead, the raw module and its TypeScript declarations are served alongside the tarball:

curl -O https://api.ijoin401k.com/embed/ijoin-embed-react.js
curl -O https://api.ijoin401k.com/embed/ijoin-embed-react.d.ts

Usage

import { useEffect, useState } from 'react';

import { IJoinEmbed } from '@ijoin/embed-react';

export const ManagedAccountEnrollment = () => {
  const [token, setToken] = useState('');
  const [agreementAccepted, setAgreementAccepted] = useState(false);

  useEffect(() => {
    fetch('/your-backend/embed-token')
      .then(r => r.json())
      .then(body => setToken(body.token));
  }, []);

  if (!token) return null;

  return (
    <>
      <IJoinEmbed
        baseUrl='https://api.ijoin401k.com'
        embedTitle='Managed Account Enrollment'
        onAgreementChanged={setAgreementAccepted}
        token={token}
        type='managed-account'
      />
      <button disabled={!agreementAccepted} type='button'>
        Deliver documents
      </button>
    </>
  );
};

Each public widget event has a dedicated, typed callback prop; widget-specific actions are documented per widget in Widgets.

The component renders nothing until baseUrl, type, and token are all present, so it is safe to mount before the token arrives.

Props

Prop Required Description
baseUrl Yes iJoin environment URL (e.g. https://api.ijoin401k.com)
type Yes Embed type; must match the embedType used when requesting the token. Typed as the union of supported widgets.
token Yes JWT returned from the token endpoint
embedTitle No Accessible label for the iframe (see Accessibility).
sandbox No iframe sandbox permissions override (see Sandboxing).
onAgreementChanged No (accepted: boolean) => void -- fired when the participant toggles the managed account disclosures agreement (see Widgets).
onLoaded No () => void -- fired once when the widget finishes its initial load.
onResize No (height: number) => void -- fired when the widget content height changes; the iframe resizes itself automatically.

Token updates

Passing a new token prop (e.g. after fetching a fresh one) updates the existing iframe session via postMessage without a full reload -- identical to the web component's token attribute behavior. Changing baseUrl or type reloads the widget.

Web Component

The <ijoin-embed> custom element works with any framework, or none. It is self-contained (no dependencies to install) and registered globally by one script tag.

Load the script

<script src="https://api.ijoin401k.com/embed/ijoin-embed.iife.js"></script>

If your build system supports ES modules, you can use the module version instead:

<script
  type="module"
  src="https://api.ijoin401k.com/embed/ijoin-embed.js"></script>

Add the component to your HTML

<ijoin-embed
  base-url="https://api.ijoin401k.com"
  type="goal-projection"
  embed-title="Retirement Goal Projection"
  token="eyJhbGciOiJIUzI1NiIs...">
</ijoin-embed>

Attributes

Attribute Required Description
base-url Yes iJoin environment URL (e.g. https://api.ijoin401k.com)
type Yes Embed type; must match the embedType used when requesting the token.
token Yes JWT returned from the token endpoint
embed-title No Accessible label for the iframe (see Accessibility).
sandbox No iframe sandbox permissions override (see Sandboxing).

Full HTML example

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>iJoin Embed Demo</title>
  <script src="https://api.ijoin401k.com/embed/ijoin-embed.iife.js"></script>
</head>
<body>
<h1>Retirement Projection</h1>

<ijoin-embed
  id="projection"
  base-url="https://api.ijoin401k.com"
  type="goal-projection"
  embed-title="Retirement Goal Projection"
  token="">
</ijoin-embed>

<script>
  fetch('/your-backend/embed-token')
    .then(r => r.json())
    .then(({ token }) => {
      document.getElementById('projection').token = token;
    });
</script>
</body>
</html>

Setting attributes dynamically

All attributes can be set or updated at any time via JavaScript. The component reacts to changes and re-renders automatically:

const widget = document.querySelector<IJoinEmbedElement>('ijoin-embed');

widget?.setAttribute('base-url', 'https://api.uat.ijoin401k.com');
widget?.setAttribute('type', 'goal-projection');
widget?.setAttribute('embed-title', 'Retirement Goal Projection');
widget?.setAttribute('token', token);

When only the token attribute changes (e.g. after a refresh), the component updates the existing iframe session via postMessage without a full reload.

TypeScript

If you're using TypeScript, declare the custom element to avoid type errors.

First, define the attribute value types:

type IJoinEmbedType =
  | 'goal-projection'
  | 'managed-account'
  | 'post-enrollment-managed'
  | 'social-security-calculator';

type IJoinBaseUrl = 'https://api.ijoin401k.com' | 'https://api.uat.ijoin401k.com';

interface IJoinEmbedAttributes {
  'base-url': IJoinBaseUrl;
  'type': IJoinEmbedType;
  'token': string;
  'embed-title'?: string;
  'sandbox'?: string;
}

For non-React TypeScript projects, extend HTMLElement with the attribute properties, override setAttribute for type-safe attribute assignment, and register the element on HTMLElementTagNameMap:

interface IJoinEmbedElement extends HTMLElement {
  'base-url': IJoinBaseUrl;
  'type': IJoinEmbedType;
  'token': string;
  'embed-title': string;
  'sandbox': string;
  setAttribute<K extends keyof IJoinEmbedAttributes>(
    name: K,
    value: IJoinEmbedAttributes[K]
  ): void;
}

declare global {
  interface HTMLElementTagNameMap {
    'ijoin-embed': IJoinEmbedElement;
  }
}

The generic setAttribute override ensures that the value passed for each attribute name matches its declared type, so typos in attribute names and invalid values for type or base-url are caught at compile time. With the HTMLElementTagNameMap declaration in place, document.querySelector('ijoin-embed') is automatically typed as IJoinEmbedElement | null.

Events

The element dispatches DOM CustomEvents:

Event When Detail
action A widget raises a user action; detail.action identifies it and the remaining detail fields carry the payload. Actions are documented per widget in Widgets. { action: string, ...payload }
resize The widget content height changes (the iframe resizes itself automatically). { height: number }

Using React? Prefer the dedicated React component over wiring the custom element into JSX.

Sandboxing

The widget iframe is sandboxed by default with allow-scripts allow-same-origin allow-forms, limiting its capabilities to only what the embed needs. Override via the sandbox attribute (Web Component) or prop (React) only if your integration requires additional capabilities (e.g. allow-popups).

Accessibility

Both integrations include the same built-in accessibility support:

  • iframe title. The embed-title attribute (embedTitle prop in React) sets the iframe's title, which screen readers announce when a user navigates into the widget. Always provide a descriptive value that explains what the widget does in your page's context. Defaults to iJoin {type} if not set.
  • Loading state. An aria-live region announces loading status to assistive technology.
  • Keyboard navigation. Users can tab into the iframe. The inner embed application handles focus management within the widget.

Troubleshooting

Symptom Cause
Nothing renders One or more required inputs (base-url/baseUrl, type, token) are missing or empty. Check the browser console for specific warnings.
Blank embed / iframe won't load Your domain isn't allowlisted -- contact iJoin
401 on token endpoint Missing, malformed, expired, or revoked API key (see Error Reference)
Embed loads then goes blank Token may have expired -- request a new one and set it again
CSP errors in browser console Add script-src and frame-src for api.ijoin401k.com to your CSP