Skip to main content
POST
Hosted Auth Link
返回一个 HostedAuthUrl,把终端用户引导到 Unipile 托管页完成 LinkedIn 登录,凭证不会经过你的系统。流程结束后 notify_url 会收到新的 account_id,正是其余端点所需。每次尝试都要新生成链接:无论 expiresOn 设成什么,链接都会在 Unipile 每日重启时失效。 参考价格:每次成功请求 $0.000001 USD。

授权

Authorization
string
header
必填

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

请求体

application/json
type
enum<string>
必填

create connects a new account, reconnect re-authenticates an existing one.

可用选项:
create,
reconnect
providers
string[]
必填

Provider list, for example ["LINKEDIN"].

api_url
string
必填

Your Unipile server URL, for example https://{subdomain}.unipile.com:{port}.

expiresOn
string

ISO 8601 UTC expiry, for example 2026-12-31T23:59:59.999Z.

name
string

Label echoed back in events so you can match the account to your own user.

notify_url
string

Callback notified once the connection completes.

success_redirect_url
string

Browser redirect after a successful connection.

failure_redirect_url
string

Browser redirect after a failed connection.

reconnect_account
string

Account id to re-authenticate. Required when type is reconnect.

响应

Success

object
enum<string>
可用选项:
HostedAuthUrl
url
string

Hosted authorization URL to send the user to.