Government Trades API Reference

Free Trial ➡

This REST API returns structured data for Government Trades - House & Senate.

Best Practices

For optimal performance, we have a few recommendations.

Limit query, improve performance

Limiting the scope of the query will directly improve the latency of the API. This can be accomplished by using parameters such as symbols, or (preferably) by using updated for deltas.

Using Deltas

A common pattern is to use a delta to query for the latest change in a dataset. By reducing the amount of data available in the query, it will produce results with the least amount of latency and limited data an application will have to traverse.

In our case, we recommend tracking and querying by the latest updated timestamp.

One caveat to allow for some latency and second-only timestamps: when querying, set updated to a value 5 seconds earlier than you actually want. A query may look like:

/government_trades?updated=LAGGED_TIMESTAMP Where LAGGED_TIMESTAMP is set to be five seconds less than the maximum value of the updated field in rows already pulled from our API.

API Endpoint
https://api.benzinga.com/api/v1/gov/usa/congress
Response Content-Types

application/json

Schemes

https

Version

1.0.0

Authentication

token authentication

Type:
apiKey
Name:
token
In:
query

Playground

Endpoints

GET /trades

Returns government trades data

Parameters

NameTypeLocationDescription
chamberstringquery

Specific chamber of congress, either House or Senate. Defaults to all of congress.

datestring (YYYY-MM-DD)query

Date to query for data. Shorthand for date_from and date_to if they are the same. Defaults for latest.

date_fromstring (YYYY-MM-DD)query

Date to query from point in time.

date_tostring (YYYY-MM-DD)query

Date to query to point in time.

fieldsstring[]query

A comma (,) separated list of returned fields.

pagesizeinteger 50query

Number of results returned. Limit 1000

pageintegerquery

Page offset.

search_keysstring (csv)query

One or more security symbols separated by a comma. Maximum 50 securities. Security identifiers must be in the format of ticker symbols, only for US-listed equities.

updated_sincenumber (double)query

Records last Updated Unix timestamp (UTC). This will force the sort order to be Greater Than or Equal to the timestamp indicated.

Timestamp may also be in python format to include millisecond updates.

Responses

CodeModelDescription
200 OK

success

Response (200 OK)

{
  "data": [
    {
      "id": "string",
      "created": "string (double)",
      "updated": "string (double)",
      "ownership": "string",
      "security": {
        "name": "string",
        "ticker": "string",
        "type": "string"
      },
      "transaction_type": "string",
      "transaction_date": "string",
      "notification_date": "string",
      "report_date": "string",
      "amount": "string",
      "chamber": "string",
      "filer_info": {
        "member_name": "string",
        "status": "string",
        "state": "string",
        "district": "string"
      }
    }
  ]
}

Models

congress_trades: object

PropertyTypeDescription
idstring

Unique ID of this signal shared across all signal types

createdstring (double)

Created timestamp, UTC.

updatedstring (double)

Last updated timestamp, UTC.

ownershipstring

The members ownership status of the asset traded (SP, JT, DC, Self, None).

securityobject

name, ticker symbol, and type of asset traded

security.namestring

name of security

security.tickerstring

ticker symbol of security

security.typestring

type of security being traded (STOCK, ETF, MUTUAL, MUNICIPAL, STOCK OPTION, CORPORATE BOND, OTHER)

transaction_typestring

Represents whether the transaction was a sale (S), partial sale (S (Partial)) or purchase (P).

transaction_datestring

The date the transaction occurred in YYYY-MM-DD format.

notification_datestring

The date the Representative claims they received notification of the transaction occurrence. This is only available for the House.

report_datestring

The date the transaction was filed in YYYY-MM-DD format.

amountstring

Represents dollar range of transaction or exact dollar amount. (e.g. $1,001 - $15,000 | $721.63).

chamberstring

Either House or Senate.

filer_infoobject

Information on filer, this has different keys for House and Senate.

filer_info.member_namestring

Name of Filer.

filer_info.statusstring

Whether filer is a Member or Former Member, it is either one or other.

filer_info.statestring

State that filer oversees (e.g. NY) - (For House Only).

filer_info.districtstring

District that filer oversees. (e.g. 06) - (For House Only).

Structure (JSON)
{
  "id": "string",
  "created": "string (double)",
  "updated": "string (double)",
  "ownership": "string",
  "security": {
    "name": "string",
    "ticker": "string",
    "type": "string"
  },
  "transaction_type": "string",
  "transaction_date": "string",
  "notification_date": "string",
  "report_date": "string",
  "amount": "string",
  "chamber": "string",
  "filer_info": {
    "member_name": "string",
    "status": "string",
    "state": "string",
    "district": "string"
  }
}