# Fund a campaign Fund a campaign from the authenticated user's wallet. Only the campaign owner can fund their campaign. Returns 200 OK on success. Requires a valid JWT access token. Endpoint: POST /campaigns/{campaignId}/fund Version: 0.1.0 Security: bearerAuth ## Path parameters: - `campaignId` (string, required) Unique identifier for the campaign Example: "campaign_abc123" ## Request fields (application/json): - `fundingAmountCents` (integer, required) Amount to fund in cents Example: 500000 - `walletCurrencyCode` (string, required) Currency code of the wallet to fund from Enum: "NGN", "USD" ## Response 200 fields (application/json): - `campaign` (object, required) - `campaign.campaignId` (string, required) Unique identifier for the campaign Example: "campaign_abc123" - `campaign.ownerUserId` (string, required) Unique identifier for the campaign owner Example: "user_123" - `campaign.campaignTitle` (string, required) Title of the campaign Example: "Summer Product Launch" - `campaign.campaignDescription` (string, required) Description of the campaign Example: "Promote our new summer product line to increase brand awareness" - `campaign.campaignObjectiveType` (string, required) Objective type for the campaign Enum: "CAMPAIGN_OBJECTIVE_AWARENESS", "CAMPAIGN_OBJECTIVE_ENGAGEMENT", "CAMPAIGN_OBJECTIVE_CONVERSIONS" - `campaign.campaignCurrencyCode` (string, required) Currency code for the campaign Enum: "NGN", "USD" - `campaign.targetBudgetAmountCents` (integer,null, required) Target budget in cents (null if no target set) Example: 1000000 - `campaign.campaignLifeCycleStatus` (string, required) Current lifecycle status of the campaign Enum: "CAMPAIGN_DRAFT", "CAMPAIGN_ACTIVE", "CAMPAIGN_PAUSED", "CAMPAIGN_COMPLETED", "CAMPAIGN_COMPLETED_WITH_REFUND", "CAMPAIGN_CANCELLED" - `campaign.campaignStartDateTimestamp` (string,null, required) Campaign start date (null if not set) Example: "2024-06-01T00:00:00Z" - `campaign.campaignEndDateTimestamp` (string,null, required) Campaign end date (null if not set) Example: "2024-08-31T23:59:59Z" - `campaign.completedAtTimestamp` (string,null, required) When the campaign was completed (null if not yet completed) Example: "2024-09-01T00:00:00Z" - `campaign.createdAtTimestamp` (string, required) When the campaign was created Example: "2024-01-01T00:00:00Z" - `campaign.lastUpdatedAtTimestamp` (string, required) When the campaign was last updated Example: "2024-01-01T00:00:00Z" - `campaignEscrow` (object, required) - `campaignEscrow.escrowId` (string, required) Unique identifier for the escrow Example: "escrow_xyz789" - `campaignEscrow.campaignId` (string, required) Unique identifier for the associated campaign Example: "campaign_abc123" - `campaignEscrow.escrowCurrencyCode` (string, required) Currency code for the escrow Enum: "NGN", "USD" - `campaignEscrow.currentEscrowBalanceAmountCents` (integer, required) Current balance in the escrow account (cents) Example: 500000 - `campaignEscrow.totalFundedAmountCents` (integer, required) Total amount funded into the escrow (cents) Example: 500000 - `campaignEscrow.totalReleasedAmountCents` (integer, required) Total amount released from the escrow (cents) - `campaignEscrow.totalRefundedAmountCents` (integer, required) Total amount refunded from the escrow (cents) - `campaignEscrow.createdAtTimestamp` (string, required) When the escrow was created Example: "2024-01-01T00:00:00Z" - `campaignEscrow.lastUpdatedAtTimestamp` (string, required) When the escrow was last updated Example: "2024-01-01T12:00:00Z" ## Response 401 fields (application/json): - `error` (string, required) Error code Example: "VALIDATION_ERROR" - `message` (string, required) Human-readable error message Example: "Invalid email address or password format" - `details` (object) Additional error details (optional) - `requestId` (string) Unique request identifier for tracing (included in X-Request-ID header) Example: "550e8400-e29b-41d4-a716-446655440000" - `timestamp` (string, required) ISO 8601 timestamp when the error occurred Example: "2024-01-01T00:00:00Z" ## Response 403 fields (application/json): - `error` (string, required) Error code Example: "VALIDATION_ERROR" - `message` (string, required) Human-readable error message Example: "Invalid email address or password format" - `details` (object) Additional error details (optional) - `requestId` (string) Unique request identifier for tracing (included in X-Request-ID header) Example: "550e8400-e29b-41d4-a716-446655440000" - `timestamp` (string, required) ISO 8601 timestamp when the error occurred Example: "2024-01-01T00:00:00Z" ## Response 404 fields (application/json): - `error` (string, required) Error code Example: "VALIDATION_ERROR" - `message` (string, required) Human-readable error message Example: "Invalid email address or password format" - `details` (object) Additional error details (optional) - `requestId` (string) Unique request identifier for tracing (included in X-Request-ID header) Example: "550e8400-e29b-41d4-a716-446655440000" - `timestamp` (string, required) ISO 8601 timestamp when the error occurred Example: "2024-01-01T00:00:00Z"