getSubscriptionOffer()

Get all information about single offer. Read more about all types of offers in Tutorial 2 - Creating Offers.

Parameters:

Name Type Description
offerId string
- required parameter

Request:

    {
    "method": "getSubscriptionOffer",
    "params": {
    "offerId": "S580476507_US"
    },
    "jsonrpc": "2.0",
    "id": 1
    }

Response:

    {
    "result": {
    "id": "S580476507_US",
    "publisherEmail": "publisher@email.com",
    "title": "not test anymorre",
    "description": "my first update with Cleeng",
    "url": "http:\/\/test.com\/page_with_content",
    "currency": "EUR",
    "country": "PL",
    "period": "week",
    "active": "1",
    "price": 75,
    "createdAt": 1353067309,
    "updatedAt": 1353067309,
    "accessToTags": [
    "hockey",
    "football"
    ]
    },
    "id": "1",
    "error": null,
    "jsonrpc": "2.0"
    }

Example:

<?php
    $offerId = 'S123123123_US';

    $cleengApi = new Cleeng_Api();

    $offerDetails = $cleengApi->getSubscriptionOffer($offerId);

    echo $offerDetails->title; //print the offer title
    

Remember! you can always check it by yourself using API Console - getSubscriptionOffer()

Back to Subscription Offers