Example prompts for vibe coding and AI-assisted development
Summarize
Summary of Example prompts for vibe coding and AI-assisted development
This guide provides ServiceNow customers with practical example prompts to effectively use Build Agent for vibe coding and AI-assisted app development on the ServiceNow AI Platform. It covers how to build data models, implement security, create business rules, generate user interfaces, and more using AI-driven prompting techniques.
Show less
Prompting Best Practices
- Each submitted message to Build Agent counts as a prompt; responding to clarifying questions also counts.
- Approve plans before Build Agent creates files to maintain control.
- Draft messages carefully before submitting to get the most value from each prompt.
- Refer to general prompting guidelines and use clear, detailed prompts to guide Build Agent.
Prompt Reference by Goal
Prompts are categorized by common development goals, with placeholders to customize for your app:
- Plan: Request detailed plans including tables, fields, roles, and business rules before creation.
- Prototype: Build a basic app with roles, flows, and UI based on key requirements.
- Brainstorm: Identify necessary tables, flows, and catalog items for a business problem.
- Discover: List editable metadata types within a scope.
- Coach: Get guidance on ideal prompts and pitfalls for specific metadata types.
- Extend: Add or modify fields, ACLs, business rules, with plan approval before applying.
- Learn: Explain ServiceNow concepts, usage, and examples.
- Debug: Troubleshoot errors with stepwise investigation and issue validation.
- Document: Generate README files and user guides for apps.
- Test: Create Automated Test Framework (ATF) tests for specific functionality.
- Security: Add role-based access controls with plan and ACL review.
- Diagram: Generate ER diagrams showing tables and relationships.
- Flow: Create flows based on triggers and email notifications.
Getting Started with Build Agent
- Prototype a Simple App: Describe a straightforward app, review the plan, and approve to build.
- Document an Existing App: Summarize architecture, data model, and roles without changes.
- Extend Existing Apps or Tables: Add fields or business rules safely with documented plans and approvals.
Starter Prompts
Use starter prompt templates to safely extend, prototype, or document apps by replacing placeholders with your details, ensuring you get plans for approval before applying changes.
Advanced Prompting Suggestions
After initial builds, continue refining your app with prompts to:
- Create and improve user interfaces.
- Generate ATF tests and test plans (QA/UAT).
- Produce release notes, change management plans, and training materials.
- Build data migration plans and workflow optimization suggestions.
- Prepare executive summaries and governance documentation.
Examples of Practical Prompts
- Build a cash management app with custom tables and states.
- Add security roles defining view and edit permissions for requesters and fulfillers.
- Create business rules triggered by workflow state changes, aligned with best practices.
- Generate tailored UIs for different user roles to submit, view, or update requests.
Governance and Compliance
Embed governance requirements directly into prompts to ensure apps meet organizational security, compliance, and quality standards. Examples include:
- Defining roles and ACLs to restrict data editing.
- Creating encrypted tables with restricted access.
- Including audit logging in workflows.
- Adding testing requirements such as ATF tests.
- Meeting compliance standards like GDPR with consent tracking.
- Generating documentation for governance reviews.
Including explicit security and compliance details in initial prompts helps produce secure and compliant applications aligned with your organization's policies.
Use these example prompts to build data models, implement security, create business rules, and generate user interfaces when building an app with ServiceNow AI Platform vibe coding and AI-assisted development tools.
To learn more about prompting, see this Community article on The fastest way to learn Build Agent prompting? Ask Build Agent.
Prompting overview and tips
For more guidelines on prompting, see General guidelines for Build Agent.
Get started with prompting
Additional prompt suggestions
- Improve generated user interfaces
- Create ATF tests
- Create QA and UAT test plans
- Create a summary of all application functionality
- Add additional industry-specific use cases
- Create an announcement
- Create a user guide
- Generate release notes
- Draft change management plans
- Create training materials for end users
- Build data migration plans
- Generate workflow optimization suggestions
- Prepare executive summary for stakeholders
Example Build Agent prompt to build an app
Prompt: Create an application that handles several types of issues related to cash management. Create a custom data model with tables for each type of request. Add fields that are typical for these types of issues to each table. Request tables should extend the Task table. Create custom states for each request type to track issue resolution.
Example Build Agent prompt to add security to an app
- Requesters who submit issues and can only view their own requests.
- Fulfillers who can view and edit all requests.
Example Build Agent prompt to add business rules to an app
Prompt: Create business rules for each request that is triggered by state changes in the workflow. Design the business rules to work together to create business processes aligned to industry best practices for each type of issue.
Example Build Agent prompt to generate different UIs for an app
Prompt 1: Create an easy to use UI for users with the cash management fulfiller role to view all issues, update and complete them.
Prompt 2: Create a UI for cash management requesters to submit issues and view or edit issues that they have previously created.
Example prompts for governance
Prompting with governance requirements helps produce secure and compliant applications on the ServiceNow AI Platform. By embedding governance requirements directly into your prompts, you help the AI produce results aligned with your organizational standards for security, compliance, and quality.
For more information on governance, see Build Agent governance.