API Documentation

Everything you need to integrate the RichAPI API into your product.

Ads


LinkedIn Ad Details

Get full details of a specific LinkedIn ad including variants, impressions by country, and targeting.

POST
/api/v1/linkedin_ad_details
2 credits per call

Parameters

FieldTypeRequiredDescription
ad_urlstringYesLinkedIn Ad Library detail URL (e.g. https://www.linkedin.com/ad-library/detail/1215501393)

Example response

json
{
  "element": {
    "about": {
      "advertiserName": "UX Pilot AI",
      "advertiserUrl": "https://www.linkedin.com/company/99850535?trk=ad_library_about_ad_advertiser",
      "format": "Single Image Ad",
      "paidBy": "UX Pilot"
    },
    "id": "1215501393",
    "impressions": null,
    "targeting": null,
    "variants": [
      {
        "advertiser": {
          "headline": "Promoted",
          "imageUrl": "https://media.licdn.com/dms/image/v2/D4E0BAQF14xfiQrSfew/company-logo_100_100/B4EZwpRV9cGcAQ-/0/1770218938904/uxpilot_ai_logo?e=1784160000&v=beta&t=dAJZSufW8CcVg1PVqad0K4AQtae4qg06TbFbHfRn-bE",
          "linkedinUrl": "https://www.linkedin.com/company/99850535?trk=ad_library_ad_preview_advertiser_image",
          "name": "UX Pilot AI"
        },
        "content": {
          "ctaLabel": "Learn more",
          "description": "Paste your PRD, generate multi-step flows with your actual components, and get screens that look like your product, in seconds, not generic AI output.\n\nSee it in action today.",
          "headline": "Generate wireframes in seconds",
          "imageUrl": "https://media.licdn.com/dms/image/v2/D4D10AQHrygtedL9DNQ/image-shrink_1280/B4DZXy8bxYHIAM-/0/1743537684174/Frame1000002823png?e=2147483647&v=beta&t=_j-yK4ZU0KcFUnEBpTGGtFYJED9-EoNv1SJGfdVWy2w",
          "targetUrl": null
        },
        "creativeType": "SPONSORED_STATUS_UPDATE"
      }
    ]
  },
  "query": {
    "url": "https://www.linkedin.com/ad-library/detail/1215501393"
  },
  "status": 200
}

Code

curl -X POST https://dev-api.richapi.ai/api/v1/linkedin_ad_details \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "ad_url": "https://www.linkedin.com/ad-library/detail/1215501393"
}'

Try it

Sign in to test this endpoint with your API key.

Sign in to try


Meta Ads Library Scraper

Scrape Meta (Facebook/Instagram) Ad Library — get active ads, creatives, spend ranges, and targeting.

POST
/api/v1/meta_ads_library_scraper_sync
1 credit per record

Parameters

FieldTypeRequiredDescription
meta_ad_urlstringYesURL of the Meta Ad to scrape
limitintNoMax results to return (max 100)

Example response

json
{
  "adArchiveID": "example",
  "adStatus": "example",
  "adText": "example",
  "ctaDomain": "example",
  "pageName": "example",
  "publisherPlatforms": [],
  "startDate": "example"
}

Code

curl -X POST https://dev-api.richapi.ai/api/v1/meta_ads_library_scraper_sync \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "meta_ad_url": "https://www.facebook.com/ads/library/?active_status=active&ad_type=all&country=US&q=clay",
  "limit": 1
}'

Try it

Sign in to test this endpoint with your API key.

Sign in to try