HomeGuidesAPI ReferenceRelease notes
Log In
Guides

Agent authentication

Once an agent is deployed, it is served behind a scalable backend API. With the agent authentication settings, the user can control whether they want this endpoint to be authenticated or not.

Configure authentication via UI

Authentication is achieved using an API token that is generated by the platform and can be accessed from the settings screen.
Once this setting is changed, it will automatically roll out for the published version and should take effect within seconds, up to one minute after the change is made.

🚧

Potential breaking change

If the agent is already deployed and does not require authentication, then enabling authentication could potentially disrupt previously integrated clients that have not been using API token authentication.

📘

Anonymous access

If the agent already has a deployed version that requires authentication and then authentication is turned off, previously connected clients with API authentication will still work as the passed API key will simply be ignored. However, turning authentication off should be carefully considered, as it means that anyone can access your agent's API, which might be connected to your organization's internal data and knowledge.

Configure authentication via SDK

Create an agent with authentication

agent = sw.agent.create(f"my agent name", authentication_enabled=True)

Change the authentication setting of an existing agent

agent = sw.agent.update(agent_id=agent.id, authentication_enabled=False)