IbkrApi.HTTP (ibkr_api v1.0.3)

View Source

HTTP client for the Interactive Brokers Client Portal API with rate limiting.

This module provides functions to make rate-limited HTTP requests to the IBKR API. Rate limits are enforced both globally and per-endpoint according to IBKR's documentation.

Summary

Functions

Returns a child specification for the HTTP client.

Makes a rate-limited DELETE request to the specified URL.

Extracts the API path from a URL.

Makes a rate-limited GET request to the specified URL.

Makes a rate-limited POST request to the specified URL.

Makes a rate-limited PUT request to the specified URL.

Applies rate limiting to the given function based on the URL.

Functions

child_spec(opts)

Returns a child specification for the HTTP client.

delete(url, headers \\ [], opts \\ [])

Makes a rate-limited DELETE request to the specified URL.

Parameters

  • url: The URL to request
  • headers: HTTP headers to include
  • opts: Additional options

extract_path(url)

Extracts the API path from a URL.

get(url, headers \\ [], opts \\ [])

Makes a rate-limited GET request to the specified URL.

Parameters

  • url: The URL to request
  • headers: HTTP headers to include
  • opts: Additional options

post(url, body, headers \\ [], opts \\ [])

Makes a rate-limited POST request to the specified URL.

Parameters

  • url: The URL to request
  • body: The request body
  • headers: HTTP headers to include
  • opts: Additional options

put(url, body, headers \\ [], opts \\ [])

Makes a rate-limited PUT request to the specified URL.

Parameters

  • url: The URL to request
  • body: The request body
  • headers: HTTP headers to include
  • opts: Additional options

with_rate_limiting(url, func)

Applies rate limiting to the given function based on the URL.