How to Implement Authentication for Vonage Cloud Runtime (VCR) Code Hub Applications How to Implement Authentication for Vonage Cloud Runtime (VCR) Code Hub Applications

How to Implement Authentication for Vonage Cloud Runtime (VCR) Code Hub Applications

Praveen Jogi

Objective

Secure all publicly accessible endpoints in a Vonage Cloud Runtime (VCR) Code Hub application to meet the new authentication requirements introduced for Code Hub submissions.

Applies To

  • Vonage Cloud Runtime (VCR)

  • Code Hub (public application marketplace)

  • VCR SDK (Node.js and Python)

  • All applications published or submitted to Code Hub


Procedure

Before you begin: Review your application's public-facing routes to identify any endpoints that make requests to Vonage APIs or third-party APIs. These must be secured.

Note: Endpoints that only serve static informational content (for example, a static HTML page that makes no external requests) may remain public.

1. Review your application's vcr.yml configuration to identify all routes and their current access levels.

2. Choose one of the following authentication approaches for each sensitive endpoint:

Option A - VCR Security Configuration (Vonage API Key Basic Authentication)

Add the following to your vcr.yml to enable platform-level authentication. The VCR gateway validates that incoming requests include your Vonage API Key Basic Authentication credentials:

instance:
  security:
    access: authenticated
    auth-method: vonage_basic
    override:
      - path: "/info"
        access: public
      - path: "/scheduler-callback"
        access: private

Note: The /info path remains public by default. The /scheduler-callback path is automatically treated as private and accessible only by internal VCR services.

Option B - Custom Authentication Middleware

Implement your own authentication logic within your application code. Supported patterns include:

  • Vonage API Key Basic Authentication

  • Vonage Application JSON Web Token (JWT) validation

  • OAuth 2.0

  • A custom token scheme appropriate to your use case

3. Test your secured endpoints to confirm that unauthenticated requests are rejected and that authorised requests succeed as expected.

4. If you have an existing application already published to Code Hub, update and resubmit it before September 7, 2026.

Note: Applications that do not meet the requirement by this deadline will be removed from Code Hub.

5. For new submissions, confirm that all sensitive routes are secured before submitting.

Note: Submissions without authentication in place will be declined.


Additional Information