> ## Documentation Index
> Fetch the complete documentation index at: https://dialnexa.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Generate Agent Tone

> Generate Agent Tone with the DialNexa API. Drafts an agent tone and inferred locale from the supplied context without changing an agent.

<span data-api-safety-label="read-only"><Badge color="gray" size="sm" shape="pill">Read only</Badge></span>

Generate Agent Tone uses your workspace API key. Drafts an agent tone and inferred locale from the supplied context without changing an agent.

## Before you begin

Use a server-side [API key](/docs/api-reference/authentication) for the intended workspace.

## Generate Agent Tone request

The request panel lists supported query parameters and body fields. For a request body, the example below supplies the required fields. Replace sample values with your own inputs.

```bash theme={null}
curl --request POST 'https://api.dialnexa.com/v1/agent-builder/generate-agent-tone' \
  --header "Authorization: Bearer $DIALNEXA_API_KEY" \
  --header 'Content-Type: application/json' \
  --data '{
  "company_and_offering": "Example company and offering",
  "target_customer": "Example target customer",
  "primary_goal": "Example primary goal",
  "success_criteria": "Example success criteria",
  "information_to_collect": "Example information to collect",
  "objections_and_faqs": "Example objections and faqs"
}'
```

## Verify the result

Expect HTTP `201`. Read the `data` property in the success envelope; the response panel documents its fields.

This operation also accepts the matching `/v1/assistant` path. The request and result contracts are shared. Use one path consistently for your integration.

## Retry safety

This operation does not modify workspace resources. Retry after a transient connection failure.

## Errors and recovery

* `401`: Missing, expired, or invalid API key.

## Related endpoints

* [Get Agent Builder Inventory](/docs/api-reference/v1/agent-builder/inventory)
* [Build Agent Configuration](/docs/api-reference/v1/agent-builder/run)
* [Stream Agent Build](/docs/api-reference/v1/agent-builder/stream)
* [Generate Agent Objectives](/docs/api-reference/v1/agent-builder/generate-objectives)
* [API authentication](/docs/api-reference/authentication)


## OpenAPI

````yaml POST /v1/agent-builder/generate-agent-tone
openapi: 3.0.0
info:
  title: DialNexa API
  description: Public `/v1` REST API for the DialNexa voice AI platform.
  version: 1.0.0
servers:
  - url: https://api.dialnexa.com
    description: DialNexa production API
security:
  - bearer: []
tags:
  - name: Agents
  - name: Batch Calls
  - name: Calls
  - name: Knowledge Base
  - name: Languages
  - name: LLMs
  - name: Phone Numbers
  - name: Transcribers
  - name: Webhooks
  - name: Voices
  - name: Workflows
  - name: Workflow Leads
  - name: Authentication
  - name: Agent Builder
paths:
  /v1/agent-builder/generate-agent-tone:
    post:
      tags:
        - Agent Builder
      summary: Generate Agent Tone
      description: >-
        Drafts an agent tone and inferred locale from the supplied context
        without changing an agent.
      operationId: generateAgentTone
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GenerateAgentTone'
            examples:
              request:
                value:
                  company_and_offering: Example company and offering
                  target_customer: Example target customer
                  primary_goal: Example primary goal
                  success_criteria: Example success criteria
                  information_to_collect: Example information to collect
                  objections_and_faqs: Example objections and faqs
      responses:
        '201':
          description: Generated agent tone
          content:
            application/json:
              schema:
                type: object
                required:
                  - success
                  - error
                  - statusCode
                  - message
                  - data
                  - timestamp
                properties:
                  success:
                    type: boolean
                    enum:
                      - true
                  error:
                    type: boolean
                    enum:
                      - false
                  statusCode:
                    type: integer
                    example: 201
                  message:
                    type: string
                    example: Success
                  data:
                    type: object
                    properties:
                      agent_tone:
                        type: string
                      inferred_region:
                        type: string
                      inferred_language:
                        type: string
                  timestamp:
                    type: string
                    format: date-time
        '401':
          description: Missing, expired, or invalid API key.
      security:
        - bearer: []
components:
  schemas:
    GenerateAgentTone:
      type: object
      properties:
        company_and_offering:
          type: string
        target_customer:
          type: string
        primary_goal:
          type: string
        success_criteria:
          type: string
        information_to_collect:
          type: string
        objections_and_faqs:
          type: string
      required:
        - company_and_offering
        - target_customer
        - primary_goal
        - success_criteria
        - information_to_collect
        - objections_and_faqs
  securitySchemes:
    bearer:
      scheme: bearer
      type: http

````