AWS Messaging Blog
Setting up an RCS agent with an AI coding assistant and AWS End User Messaging
Clone a repo, open it in your AI coding assistant, type “go,” and walk away with a working RCS agent.
Creating an RCS agent on AWS End User Messaging normally means juggling 23 registration fields, three different CLI parameter types, brand asset requirements, and a multi-step approval process. An AI coding assistant can handle all of that for you. With AWS End User Messaging, you can create RCS agents that send and receive rich messages complete with your brand’s logo, colors, and verified identity.
Setting up an RCS agent involves creating an agent container, uploading brand assets, configuring a 23-field registration, submitting for approval, adding verified testers, and testing both outbound and inbound messaging. Each field has a specific type (TEXT, SELECT, or ATTACHMENT) that requires a different CLI parameter, and getting any of them wrong means starting over.
We built an open-source sample repository that encodes all of this knowledge into an AGENTS.md file. When you open the repo in an AI coding assistant like Kiro, Cursor, or Windsurf, the assistant reads the instructions and walks you through the entire setup interactively. You provide a brand name and your phone number. The AI handles everything else.
How it works
The repository aws-samples/sample-rcs-agent-setup-and-send-messages contains:
AGENTS.md— A structured instruction file that AI coding assistants read automatically. It contains the complete RCS agent setup workflow: credential checks, brand asset generation, registration field configuration, tester management, and message testing.brand-assets/— Template SVG files for the agent logo (224×224 px) and banner (1440×448 px), ready to be customized and converted to PNG..kiro/steering/rcs-agent-setup.md— A Kiro-specific steering file with the same instructions, using theinclusion: alwaysfrontmatter so Kiro loads it automatically.
The AGENTS.md file is the key. It defines six skills that the AI assistant executes in sequence:
- Create RCS agent — Creates the agent container, generates brand assets (logo and banner SVGs), converts them to PNG, creates a test registration, sets all 23 fields with the correct parameter types, and submits for approval.
- Add verified testers — Registers test phone numbers and guides you through accepting the tester invitation.
- Send a test message — Checks for blockers (protect configuration, opt-out lists) and sends your first branded RCS message.
- Set up inbound keyword — Configures an automatic response keyword so you can test inbound messaging without writing backend code.
- Verify inbound messaging — Walks you through the console deep link flow to confirm two-way messaging works.
- Delete an RCS agent — Removes an agent cleanly by disabling deletion protection, deleting the associated registration, then deleting the agent itself.
Prerequisites
Before you start, you need:
- An AWS account with access to AWS End User Messaging.
- AWS Command Line Interface (AWS CLI) v2.35.12 or later installed and configured with credentials that have
pinpoint-sms-voice-v2:*permissions. - An AI coding assistant that reads
AGENTS.mdfiles (Kiro, Cursor, Windsurf, or similar). - librsvg for SVG to PNG conversion (
brew install librsvgon macOS). - A test phone that supports RCS messaging.
Getting started
Follow these steps to go from zero to a working RCS agent. The entire process takes about five minutes.
Step 1: Clone the repository
Step 2: Open in your AI coding assistant
Open the cloned directory in your preferred AI coding assistant. The assistant will automatically detect the AGENTS.md file (or .kiro/steering/rcs-agent-setup.md if you are using Kiro).
Step 3: Type “go”
In the chat panel, type go. The AI assistant will:
- Check your AWS credentials — It runs
aws sts get-caller-identityand asks how you authenticate if credentials are not configured. It supports named profiles, SSO, IAM user credentials, and environment variables. - Verify EUM access — It confirms your account can use AWS End User Messaging.
- Check tooling — It verifies
rsvg-convertis installed for brand asset generation. - Ask for your preference — Quick mode (provide a brand name) or interactive mode (you specify every detail).
Step 4: Provide a brand name
In quick mode, you provide a brand name and the AI generates everything else: a description, an accessible accent color, contact information with placeholder values, privacy and terms URLs, and custom SVG brand assets with your brand name and colors.
In interactive mode, the AI asks for each detail one section at a time: brand name, accent color, logo description, banner description, contact information, and policy URLs.
Step 5: Watch it work
The AI assistant executes every AWS CLI command in sequence:
- Creates the RCS agent container.
- Enables deletion protection.
- Creates a test registration and links it to the agent.
- Generates and converts brand asset SVGs to PNG.
- Uploads the logo and banner as registration attachments.
- Sets all 23 registration fields using the correct parameter type for each (TEXT, SELECT, or ATTACHMENT).
- Submits the registration and polls for approval.
- Reports when the agent is active.
Step 6: Add a tester and send a message
Once the agent is approved, the AI asks for your test phone number, registers it as a verified tester, and waits for you to accept the invitation. After verification, it checks for blockers (protect configuration and opt-out lists), then sends your first branded RCS message.
Step 7: Test inbound messaging
The AI configures an automatic keyword response and walks you through the console deep link flow to verify two-way messaging. When you send RCSINBOUNDTESTING to your agent, you receive an automatic reply confirming inbound messaging works.
What the AI handles for you
The AGENTS.md file encodes several non-obvious behaviors that would otherwise require trial and error:
| Challenge | How the repo handles it |
create-rcs-agent takes no --display-name parameter |
The brand name comes from the registration, not the agent creation call. The instructions reflect this. |
| Three different field parameter types | The instructions include a field reference table mapping each of the 23 fields to its correct CLI parameter: --text-value, --select-choices, or --registration-attachment-id. |
--field-values does not exist |
The instructions explicitly warn against this non-existent parameter and use the correct alternatives. |
--attachment-body and --attachment-url conflict |
The instructions use --attachment-body only. |
| Accent color contrast requirements | The instructions include pre-validated color choices with 4.5:1 contrast ratio against white. |
| Field paths differ from what you might expect | The correct paths are agentDetails.logoImage and agentDetails.bannerImage, not logoAttachmentId or bannerAttachmentId. |
| New registration versions do not inherit field values | The troubleshooting section warns that all 23 fields must be re-populated when creating a new version. |
Customizing the repo
You can modify the AGENTS.md file to fit your workflow:
- Change default values — Update placeholder contact information, privacy URLs, or terms URLs to match your organization.
- Add custom brand assets — Replace the template SVGs in
brand-assets/with your own designs. Keep the logo at 224×224 px and the banner at 1440×448 px. - Extend the skills — Add new skills for richer message types (cards, carousels), event destinations for programmatic inbound handling, or integration with other AWS services.
Cleanup
To remove the resources created during testing:
Note: You must delete the registration before the agent. Skipping this step results in a ConflictException: RESOURCE_NOT_EMPTY error.
Conclusion
The aws-samples/sample-rcs-agent-setup-and-send-messages repository turns a multi-step, error-prone CLI workflow into a guided conversation. Clone the repo, open it in your AI coding assistant, type “go,” and you have a working RCS agent that can send and receive branded messages to verified testers.
The AGENTS.md pattern is reusable. Any complex AWS workflow with non-obvious API behavior can be encoded the same way: document the correct commands, parameter types, and pitfalls in a structured file, and let the AI assistant execute it interactively.
For a detailed manual walkthrough of the same process, see Creating and testing an RCS agent with AWS End User Messaging. For an overview of the business case for RCS, see Upgrade business messaging with RCS on AWS. For more information, see the AWS End User Messaging service page and the RCS documentation.