Get Info by shortcode
Retrieve media information by media shortcode. This method provides the same information as the Get Info.
Params
Name | Type | Default | Description |
---|---|---|---|
shortcode (required) | string | – | Media shortcode |
Usage
- Python
- PHP
- cURL
from rocketapi import InstagramAPI
instagram_api = InstagramAPI(token="your-api-key")
print(instagram_api.get_media_info_by_shortcode("Cm9DyYNooPD"))
<?php
require('vendor/autoload.php');
use RocketAPI\InstagramAPI;
$api = new InstagramAPI('your-api-key');
print_r($api->getMediaInfoByShortcode("Cm9DyYNooPD"));
curl --request POST \
--url https://v1.rocketapi.io/instagram/media/get_info_by_shortcode \
--header 'Content-Type: application/json' \
--header 'Authorization: Token your-api-key' \
--data '{
"shortcode": "Cm9DyYNooPD"
}'
Response example
Loading...