Connect a Guild.ai agent to BasicOps so it can work as an Agent User: a dedicated AI team member that can receive BasicOps messages, respond in context, and take action from inside your workspace.
This article will show you how to:
- Create an Agent User and API key in BasicOps
- Connect BasicOps to Guild.ai
- Fork and publish the BasicOps team member agent template
- Create and activate the Guild.ai trigger
- Register the webhook connection with BasicOps
- Use the agent in BasicOps
Before you start
Make sure you have:
- A BasicOps account. If you do not have one, sign up at https://app.basicops.com/signup?agents.
- A Guild.ai account. Go to https://www.guild.ai/, select Sign in, and create a new account if needed.
- Access to the BasicOps connect to BasicOps as Agent User template in Guild.ai: https://app.guild.ai/hub/agents/basicops~connect-to-basicops-as-agent-user
Create the Agent User and API key in BasicOps
First, create a dedicated Agent User in BasicOps. This gives the Guild.ai agent its own identity and API key.
- In BasicOps, select Settings in the left sidebar.
- Select Users.
- Open the Agents tab.
- Click Add Agent.
- Enter the name you want to use for the agent.
- Click Add Agent.
- When the Add API Key dialog appears, enter a key name, such as the agent name.
- Click Add API Key.
- Copy the API key shown in the next dialog and store it somewhere safe. You will need it when connecting Guild.ai to BasicOps.
Connect BasicOps in Guild.ai
Next, connect Guild.ai to BasicOps using the agent API key you created.
- In Guild.ai, open the BasicOps integration page: https://app.guild.ai/hub/integrations/basicops~basicops.
- Click Connect.
- Paste the BasicOps agent API key into the API Key field.
- Click Connect to save the integration.
Add the BasicOps team member agent template
After the integration is connected, add the BasicOps team member agent template to your Guild.ai workspace.
- Open the BasicOps connect to BasicOps as Agent User template in Guild.ai: https://app.guild.ai/hub/agents/basicops~connect-to-basicops-as-agent-user
- Click the menu icon next to the agent name.
- Select Fork agent.
- Click Continue.
- Update the Agent Name.
- Select a category.
- Click Continue.
- Click Open Editor.
- After the build finishes, click Publish in the top right.
- Click Next.
- Click Add next to the workspace where you want to add the agent.
- Click Next, then click Done.
Create the Guild.ai trigger
Create an event trigger so Guild.ai can send BasicOps events to the agent.
- In Guild.ai, open your workspace from the left sidebar.
- Select the Triggers tab.
- Click Add Trigger.
- Choose Event.
- For Service, select basicops.
- For Event Type, select push.
- For Agent, select the BasicOps agent.
- Click Create Trigger.
Copy the Guild.ai webhook URL
The webhook URL is the endpoint BasicOps will use to send messages to the Guild.ai agent.
- In the same Guild.ai workspace, select the Credentials tab.
- Click Manage Credentials in the top right.
- In the credentials list, click the settings icon for basicops.
- Enable webhooks.
- Copy the webhook URL that appears.
- Leave the Webhook Secret field empty for now and keep this tab open. Do not save yet.
Generate the webhook secret
Use the BasicOps agent template to register the webhook and generate a signing secret.
- Open a second browser tab and return to your Guild.ai workspace.
- Select the Agents tab.
- Find the BasicOps agent row.
- Click the menu icon at the far right.
- Select Test agent.
- In the chat box, paste the message below. Replace [PASTE YOUR WEBHOOK HERE] with the webhook URL you copied. Leave [signature] and [payload-id] exactly as written.
Call connect_agent with webhook set to [PASTE YOUR WEBHOOK HERE], set kind to guild, set headers to: {"X-Guild-Webhook-Signature":"[signature]","X-Guild-Webhook-ID":"[payload-id]"}, set Signing to "generate", then show the generated secret.- Copy the secret returned by the agent.
Save and activate the trigger
After the webhook secret is generated, save it in Guild.ai and activate the trigger.
- Return to the first Guild.ai tab where the webhook credential is open.
- Paste the generated secret into the Webhook Secret field.
- Click Save.
- Return to the Triggers tab.
- Find the BasicOps trigger row.
- Click the menu icon at the far right.
- Select Activate.
Use the agent in BasicOps
Once the trigger is active, the Guild.ai agent can receive BasicOps messages.
- In BasicOps, @mention the Agent User in any message to ask it to help.
- To use the agent in a project, first add it to the project team.
- In a direct chat with the agent, @mentioning is not required.
Troubleshooting
If the agent does not respond in BasicOps, check the following:
- The BasicOps integration in Guild.ai is connected with the correct Agent User API key.
- The Guild.ai trigger is active.
- The webhook URL and webhook secret are saved in Guild.ai.
- The Agent User has access to the BasicOps channel, task, project, or direct chat where you are messaging it.
Article is closed for comments.