Subscriptions
Get a Member Plan
Retrieve a single member plan (subscription) by ID and inspect its current access and lifecycle state.
GET https://api.dyntube.com/v1/member-plans/{id}
Headers
| Name | Type | Description |
|---|---|---|
| Authorization | String | Bearer YOUR_API_KEY |
Path Parameters
| Name | Type | Description |
|---|---|---|
| id | String | Member plan ID |
Query Parameters
None.
200: OK
json
{
"id": "154Tr3xdUSvm3uKICa92w",
"name": "Video Plan Nov 2025",
"storePlanType": 1,
"planType": 3,
"planId": "ixaD0JBAOU2qT9cxYTrYWA",
"memberId": "Dq77UeAJEDQFSkYJMkcg",
"startDate": "2025-12-05T12:57:07.067Z",
"endDate": "2025-12-15T12:57:07.067Z",
"cancelAt": "2025-12-15T12:57:07.067Z",
"cancelAtPeriodEnd": true,
"currentPeriodStart": "2025-12-05T12:57:07.067Z",
"currentPeriodEnd": "2025-12-15T12:57:07.067Z",
"status": 1,
"created": "2025-12-05T12:57:07.067Z",
"updated": "2025-12-05T13:07:10.307Z"
}404: Not Found
json
{
"message": "Subscription not found"
}Error Responses
| Status Code | Description |
|---|---|
| 400 | Bad Request |
| 401 | Unauthorized |
| 404 | Member plan not found |
Notes
- Response includes lifecycle fields (cancelAt, cancelAtPeriodEnd, currentPeriodStart, currentPeriodEnd) for scheduling and access checks.
- Uses the same authentication and account scoping as other /v1/member-plans calls.
Code Samples
C#
csharp
using System.Net.Http;
using System.Net.Http.Headers;
using System.Threading.Tasks;
var client = new HttpClient();
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", "YOUR_API_KEY");
var response = await client.GetAsync("https://api.dyntube.com/v1/member-plans/{id}");
var body = await response.Content.ReadAsStringAsync();Node.js
javascript
const axios = require('axios');
axios.get('https://api.dyntube.com/v1/member-plans/{id}', {
headers: { Authorization: 'Bearer YOUR_API_KEY' }
}).then(res => console.log(res.data));Python
python
import requests
resp = requests.get(
'https://api.dyntube.com/v1/member-plans/{id}',
headers={'Authorization': 'Bearer YOUR_API_KEY'}
)
print(resp.json())PHP
php
<?php
$ch = curl_init("https://api.dyntube.com/v1/member-plans/{id}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ["Authorization: Bearer YOUR_API_KEY"]
]);
$response = curl_exec($ch);
curl_close($ch);
echo $response;Related Pages
- Get member's plans to list all assigned plans for a member.
- Manage member plan lifecycle to change the assignment state.
- Get a member to inspect the member record.
Something missing or wrong here? Tell us and we will correct it. New to DynTube? Start with uploading and embedding.