Skip to Content
Anti-detect ProvidersGPM Login

GPM Login

GPM Login  is a popular anti-detect browser. The SDK provides a built-in adapter.

Setup

import { AntidetectBaseFlow, AntidetectProvider, FlowLogger, IScriptContext, } from '@hira-core/sdk' export default class MyFlow extends AntidetectBaseFlow<typeof config> { constructor(provider: AntidetectProvider = AntidetectProvider.GPM) { super(provider, new FlowLogger('MyFlow'), config) } }

GPM must be running locally. Default API: http://127.0.0.1:19995

How it works

  1. SDK calls GPM API to start a profile → GPM launches a Chromium browser
  2. SDK connects via Puppeteer using the remote debugging address
  3. When the profile finishes, SDK calls GPM API to close the profile

GPM API Endpoints Used

ActionEndpoint
List profilesGET /api/v3/profiles
Start profilePOST /api/v3/profiles/start
Close profileDELETE /api/v3/profiles/close/{id}

Example 1 — Basic GPM flow

export default class GpmFlow extends AntidetectBaseFlow<typeof config> { constructor(provider: AntidetectProvider = AntidetectProvider.GPM) { super(provider, new FlowLogger('GpmFlow'), config) } async script(context: IScriptContext<typeof config>) { const browser = new BrowserUtils(context) // GPM profile is already opened and connected context.logger.info(`Profile: ${context.profile.name}`) context.logger.info(`Proxy: ${context.profile.raw_proxy}`) await browser.goto('https://example.com') // ... your automation } }

Custom API URL

If GPM is running on a different port, set the environment variable in .env:

GPM_API_URL=http://127.0.0.1:20000
Last updated on