Skip to main content
Localpayment provides an endpoint to retrieve detailed information about existing subscription plans. This guide explains how to fetch subscription plan details through Localpayment’s API, allowing you to verify plan configurations, check status, and use plan information in your application.

Before You Begin

Ensure you have:

API Credentials

Valid API credentials and access token for authentication.

Account Setup

Proper account setup for your target country and business verification.

IP Whitelisting

Whitelist your server IP addresses for API access.

Webhook Endpoint

Set up a webhook URL to receive payment notifications.

Step 1: Get Subscription Plan Details

To retrieve subscription plan information, send aGET request to the Get Subscription Plan endpoint.

Key Request Parameters

The request requires several key parameters:

Example Request

Below is an example using curl:
curl
See all available parameters in the request.

Step 2: Handle the Response

Successful Response

A successful request returns complete subscription plan details:

Key Response Fields

Error Response

When a subscription plan cannot be found or accessed, you’ll receive error information:

Step 3: Track Transaction Status

After retrieving a subscription plan, you can determine its availability and current state:

Webhooks (Recommended)

Receive real-time notifications when transaction status changes. Most efficient for production environments.

Status API Endpoint

Query transaction status programmatically. Useful for polling or recovering lost webhook notifications.

Business Portal View

Visual interface for monitoring transactions. Great for manual oversight and detailed transaction analysis.

Common Status Codes

Complete ReferenceView all status codes in our Transaction Status Documentation.

Testing Your Integration

Test Scenarios

Verify your integration handles these scenarios:
  1. Successful Plan Retrieval: Fetch details for an existing active plan.
  2. Nonexistent Plan: Attempt to retrieve a plan that doesn’t exist.
  3. Invalid Plan ID: Test with malformed or incorrect internalId formats.
  4. Authentication Failures: Retrieve plans with invalid or expired access tokens.

Next Steps

Create a subscription plan

Set up new subscription plans for different service tiers or pricing models.

Update subscription plan

Modify existing plan details based on the information retrieved.

Create subscription with plan

Use the plan id to create new customer subscriptions.
Last modified on November 10, 2026