Project API Keys

Integrating PayRam into your project starts with generating API keys. These keys are essential for:

  • Validating webhook calls to your application server

  • Requesting payments from your application server

Currently, the API key generation feature is a work in progress (WIP) in the PayRam dashboard. In the meantime, you can use the following APIs to generate an API key for your project.

Step 1: Fetch a New API Key for Your Root Account

Use the following API to generate a root-level API key for your account.

curl --location --request POST '<http://yourpayramserver.com:8080/api/v1/signin>' \\
--header 'Content-Type: application/json' \\
--data-raw '{
    "email": "[email protected]",
    "password": "******"
}'

Step 2: Generate API Keys for Your Projects

Once you have the root API key (for example api key f8fee50cc87bd162a08adc48880f63e4 from the previous response , use it to generate API keys for individual projects added during the PayRam setup.

🔹 externalPlatformID: A numeric identifier representing your projects:

  • 1 for the first project

  • 2 for the second project

  • and so on...

curl --location --request POST '<http://yourpayramserver.com:8080/api/v1/api-key>' \\
--header 'API-Key: f8fee50cc87bd162a08adc48880f63e4' \\
--header 'Content-Type: application/json' \\
--data '{
    "externalPlatformID": 1,
    "roleName": "platform_admin"
}'

Usage of the Project API Key

The generated project API key (ad9db0a5e2e720eaa07a573b4142b51b) must be used for:

✅ Webhook validation

✅ Generating payment links

This API key remains valid indefinitely for your project setup until you disable it from payram dashboard


Next Steps

  • Securely store your API keys and do not expose them in public repositories.

  • Use the project API key for making authorized API requests within your PayRam integration.

  • Stay updated with the PayRam dashboard for managing API keys when the feature is officially released.

Last updated