Skip to content

Add CCTP REST API endpoints for initiating and tracking cross-chain USDC transfers #184

@grantfox-development

Description

@grantfox-development

Overview

Expose the CCTP service layer through versioned REST API endpoints so the frontend and external integrators can initiate, monitor, and complete cross-chain USDC transfers.

Endpoints to Implement

Method Path Description
POST /api/v1/cctp/transfers Initiate a new CCTP transfer
GET /api/v1/cctp/transfers/:id Get transfer status and details
GET /api/v1/cctp/transfers List transfers for the authenticated user/org
POST /api/v1/cctp/transfers/:id/mint Manually trigger mint step (for manual-relay flow)

Tasks

  • Create CCTPController and register routes in the Express router
  • Add request validation DTOs (amount, sourceChain, destinationStellarAddress)
  • Add authentication middleware guard (organization role required)
  • Return proper HTTP status codes and error payloads
  • Add OpenAPI/Swagger annotations for all endpoints
  • Rate-limit the POST /transfers endpoint to prevent abuse

Acceptance Criteria

  • All endpoints return correct responses per the OpenAPI spec
  • Invalid inputs return 400 with descriptive messages
  • Unauthenticated requests return 401
  • Swagger docs updated and accessible at /api/docs
  • Controller layer has unit tests with mocked CCTPService

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions