Skip to main content

geekflare-api

Official Python SDK for the Geekflare.

  • API version: 1.0.0
  • Package version: 0.3.2

Requirements.

Python 3.10+

Installation & Usage

pip install

pip install geekflare-api

Quick Start

from geekflare_api.client import GeekflareClient
from geekflare_api.models import WebScrapeDto

with GeekflareClient(api_key="your-api-key") as client:
    result = client.web_scrape(WebScrapeDto(url="https://toscrape.com/"))
    print(result)

Available Methods

Method Description
client.meta_scrape(body) Scrape meta tags from a URL
client.web_scrape(body) Scrape web page content
client.brand(body) Get structured brand and company information for a domain
client.dns_record(body) Look up DNS records
client.screenshot(body) Take a screenshot of a URL
client.site_status(body) Check if a site is up or down
client.redirect_check(body) Check redirect chain of a URL
client.broken_link(body) Find broken links on a page
client.url2_pdf(body) Convert a URL to PDF
client.open_ports(body) Scan open ports on a host
client.tls_scan(body) Scan TLS/SSL configuration
client.load_time(body) Test page load time
client.mixed_content(body) Check for mixed content issues
client.dns_sec(body) Check DNSSEC configuration
client.mtr(body) Perform MTR network test
client.ping(body) Ping a host
client.lighthouse(body) Run Lighthouse audit
client.search(body) Perform a web search

Error Handling

import geekflare_api
from geekflare_api.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.geekflare.com
# See configuration.py for a list of all supported configuration parameters.
configuration = geekflare_api.Configuration(
    host = "https://api.geekflare.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: x-api-key
configuration.api_key['x-api-key'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['x-api-key'] = 'Bearer'


# Enter a context with an instance of the API client
with geekflare_api.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = geekflare_api.ApiToolApi(api_client)
    broken_link_dto = geekflare_api.BrokenLinkDto() # BrokenLinkDto |

    try:
        # Check if a webpage contains broken links
        api_response = api_instance.broken_link(broken_link_dto)
        print("The response of ApiToolApi->broken_link:\n")
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling ApiToolApi->broken_link: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://api.geekflare.com

Class Method HTTP request Description
ApiToolApi brand POST /brand Get brand data for a domain
ApiToolApi broken_link POST /brokenlink Check if a webpage contains broken links
ApiToolApi crawl_cancel_api POST /crawl/{id}/cancel Cancel a running crawl
ApiToolApi crawl_download_api GET /crawl/{id}/download Get a ZIP of the crawled pages
ApiToolApi crawl_errors_api GET /crawl/{id}/errors List failed pages of a crawl with error details
ApiToolApi crawl_list_api GET /crawl List crawls
ApiToolApi crawl_start_api POST /crawl Start an asynchronous crawl
ApiToolApi crawl_status_api GET /crawl/{id} Get crawl status, progress, timing and pages
ApiToolApi crawl_sync_api POST /crawl/sync Crawl a small site and return page content in the same response
ApiToolApi crawl_trace_api GET /crawl/{id}/trace Show how a URL was reached from the seed
ApiToolApi crawl_webhooks_api GET /crawl/{id}/webhooks List webhook deliveries for a crawl
ApiToolApi dns_record POST /dnsrecord Retrieve DNS records for a given domain
ApiToolApi dns_sec POST /dnssec Check if DNSSEC is enabled for a domain
ApiToolApi lighthouse POST /lighthouse Run Lighthouse audit on a website
ApiToolApi load_time POST /loadtime Measure the page load time for a given URL
ApiToolApi map_api POST /map Map the URLs of a website
ApiToolApi map_async_api POST /map/async Start a map as a background job
ApiToolApi map_async_status_api GET /map/async/{id} Get map job status/result
ApiToolApi meta_scrape POST /metascraping Scrape a webpage meta with custom options
ApiToolApi mixed_content POST /mixedcontent Check for mixed content on a site
ApiToolApi mtr POST /mtr Perform MTR (My Traceroute) network diagnostic test
ApiToolApi open_ports POST /openport Scan a website for open ports
ApiToolApi ping POST /ping Perform ICMP Ping test on a given URL or IP
ApiToolApi redirect_check POST /redirectcheck Check the redirection chain of a given URL
ApiToolApi screenshot POST /screenshot Capture a full-page screenshot of a website
ApiToolApi search POST /search Search API for AI Agents & LLMs
ApiToolApi site_status POST /up Check if a site is up or down
ApiToolApi tls_scan POST /tlsscan Perform TLS scan for a given domain
ApiToolApi url2_pdf POST /url2pdf Capture a full-page Url2Pdf of a website
ApiToolApi web_scrape POST /webscraping Scrape a webpage with custom options

Documentation For Models

Documentation For Authorization

Authentication schemes defined for the API:

x-api-key

  • Type: API key
  • API key parameter name: x-api-key
  • Location: HTTP header

bearer-token

  • Type: Bearer authentication (JWT)

gf_auth_session

  • Type: API key
  • API key parameter name: gf_auth_session
  • Location:

License

MIT

mcp-name: com.geekflare/mcp

Metadata

Release files for geekflare-api 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for geekflare-api 0.4.0
File Size Uploaded Provenance Actions
geekflare_api-0.4.0.tar.gz 134.6 kB Without provenance Details for geekflare_api-0.4.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for geekflare-api 0.4.0
File Interpreter ABI Platform Actions
geekflare_api-0.4.0-py3-none-any.whl Python 3 none any Details for geekflare_api-0.4.0-py3-none-any.whl

Total release size: 437.1 kB

Release files / geekflare_api-0.4.0.tar.gz

Download URL geekflare_api-0.4.0.tar.gz
Size 134.6 kB
Tags Source
SHA-256 checksum
How to use checksums
522834a5f73f623ab79a5ac8e515f58c0f2e35263378fd2d301b93552b2b6332
BLAKE2b-256 checksum
How to use checksums
f41929d75724c9a79ea580af1e8670aa758407fc425f88c524610482b1cba5d8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.10

Release files / geekflare_api-0.4.0-py3-none-any.whl

Download URL geekflare_api-0.4.0-py3-none-any.whl
Size 302.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b8eca359355d5d2091e972f17beeb5b0045701ca106c03a3272793d94db04103
BLAKE2b-256 checksum
How to use checksums
fd4e47f14a36c5ed7928bfaf9358eaa717725f2957769d192b9285271489aeb1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.10

Security for geekflare-api 0.4.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page