LogoLogo
  • What Is Junkipedia?
    • Introduction
    • What You Can Do
    • What You Can't Do
    • Tip-Issue-Narrative Pipeline
  • Getting Started
    • Managing Your Team
      • Inviting New Users
      • Managing Your Organization
    • Setting Up Tiplines
      • Creating A New Tipline
      • Configuring Tipline Properties
        • Hosting A Web Tipline
        • Hosting An Email Tipline
        • Hosting An SMS Tipline
        • Hosting A Whatsapp Tipline
        • Hosting A Slack Tipline
        • Hosting An API Tipline
      • Embedding A Tipline Form
      • Sharing A Tipline Via QR Code
      • Enabling Inbound Tip Review
      • Disabling A Tipline
      • Adding Default Topics & Tags (wip)
      • Reviewing Tips
    • Reporting And Documenting Misinformation
      • Submitting Tips Within Junkipedia
      • Using Tiplines Outside Of Junkipedia
        • Submit A Tip via SMS
        • Submit A Tip via Email
        • Submit A Tip Via WhatsApp
        • Submit A Tip via Slack
        • Submit A Tip via Web Form
        • Submit Tips Via API
      • Editing An Issue
        • The "Edit Issue" Form
        • What To Include
        • Adding More Tips To An Issue
        • Editing Within The Issues List
          • Issue Title & Description
          • Adding Tags To An Issue
          • Linking Issues To Narratives
    • Reviewing Tracked Content
      • Searching For Issues
      • Filtering Issues
      • Creating Saved Search Alerts
    • Managing Narratives
      • Adding Issues To A Narrative
      • Describing A Narrative
      • Preparing A Response
      • Making A Narrative Public
    • Social Media Monitoring
      • Introducing The Junkipedia Monitoring System
      • Searching The Database
      • Following Public Lists
      • Building Your Own Lists
      • Edit an Existing List
      • Sharing your lists
      • Using Actor Sets
  • Reference Material
    • Glossary
    • API
      • Using Your API Key
      • Query String Parameters
        • Text Search Parameters
        • Engagement Filters
        • Pagination
        • Post Type And Platform
        • Time Filters
        • Language Code
        • Channel Properties
        • Exclude
        • Lists
    • Best Practices
      • Fact Checking
        • Verification Resources
        • How to Verify Online Information
      • How to Find Misinformation Online
      • social media post
      • Instagram via CrowdTangle
      • Protect Your Mental Well Being
    • User Account Admin
      • Update Your User Profile Details
      • Update Your Security Settings
Powered by GitBook
On this page
  • Obtain An API Key
  • Prepare Request Header With API Key
  • Determine Request Method, Endpoint, Inputs, And URL
  • Compose And Issue The Request
  1. Reference Material
  2. API

Using Your API Key

PreviousAPINextQuery String Parameters

Last updated 1 year ago

All of the API endpoints described in this document require an API Key in the form of an OAuth 2.0 Bearer Token to be included in the authorization header of each request. The following specific instructions and examples walk through the process of using the Junkipedia API with this key.

Obtain An API Key

A valid API Key will be a string of digits mixed with upper and lower case letters. In the examples that follow, we will use Xyz123ApiKey as a placeholder for your actual API Key.

You can use your Junkipedia.org account to obtain an API Key with the following steps:

  1. Login to Junkipedia.org and navigate to from from the pulldown menu under your avatar icon in the upper right hand corner of the window.

  2. Click on "Manage API Keys".

  3. You can use any of the API Keys listed unless they are disabled. You can click "Create API Key" if there are none available.

Prepare Request Header With API Key

The header of each request will include an and authorization header line similar to the following:

  • Authorization: Bearer Xyz123ApiKey

Prepare an authorization line in this format using your own API Key.

Determine Request Method, Endpoint, Inputs, And URL

Use to select a desired endpoint and request method. For example, the request uses the "GET" method with the "/posts" endpoint.

When issuing any request from the Junkipedia API, the endpoint is appended to the following common Base Path identifying Junkipedia's API server:

If the request includes query string input parameters, the URL will include a "?" appended after the endpoint name and followed by the URL encoded parameters. Examples of available parameters are given in the documentation for each endpoint.

If the request accepts input via the request body, it will be given in the form of a JSON object and appropriate examples will appear in the documentation for each endpoint. In general, an endpoint may accept input parameters either via query string or request body but not both ways.

Compose And Issue The Request

curl --header 'Authorization: Bearer Xyz123ApiKey' \ --request GET 'https://www.junkipedia.org/api/v1/posts'

Note that the backslash character at the end of the first line in the command above is simply there to cause the newline character to be ignored so that the command can span two lines.

The following command issues a request to the same endpoint but this time passes one parameter in a URL encoded query string.

curl --header 'Authorization: Bearer Xyz123ApiKey' \ --request GET 'https://www.junkipedia.org/api/v1/posts?keyword=potus'

Using a programming language, script, or other tool, the elements mentioned above can be combined and issued as a request. The following example uses CURL to issue a request without any input parameters.

your user account page
the list of available endpoints
GET /posts
https://www.junkipedia.org/api/v1
GET /posts