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

# Request disabling voice on a SIM card

> This API disables voice calling on a SIM card. The SIM card will no longer be able to make or receive calls.<br/>
The API will trigger an asynchronous operation called a SIM Card Action. The status of the SIM Card Action can be followed through the [List SIM Card Action](https://developers.telnyx.com/api-reference/sim-card-actions/list-sim-card-actions) API.




## OpenAPI

````yaml /openapi/source/external/wireless/wireless.json post /sim_cards/{id}/actions/disable_voice
openapi: 3.1.0
info:
  version: 2.0.0
  title: Telnyx API
  x-latency-category: responsive
  x-endpoint-cost: light
  description: SIP trunking, SMS, MMS, Call Control and Telephony Data Services.
  contact:
    email: support@telnyx.com
servers:
  - url: https://api.telnyx.com/v2
    description: Version 2.0.0 of the Telnyx API.
security:
  - bearerAuth: []
tags:
  - name: Wireless
    description: Wireless operations
  - name: SIM Cards
    description: SIM Cards operations
  - name: SIM Card Actions
    description: >-
      View SIM card actions, their progress and timestamps using the SIM Card
      Actions API
  - name: SIM Card Groups
    description: SIM Card Groups operations
  - name: SIM Card Group Actions
    description: SIM Card Group actions operations
  - name: SIM Card Orders
    description: SIM Card Orders operations
  - name: Reporting
    description: Wireless reporting operations
  - name: Wireless Regions
    description: Regions for wireless services
  - name: OTA updates
    description: OTA updates operations
  - name: Mobile Network Operators
    description: Mobile network operators operations
  - name: Private Wireless Gateways
    description: Private Wireless Gateways operations
  - name: Wireless Blocklists
    description: Wireless Blocklists operations
  - name: Traffic Policy Profiles
    description: Traffic Policy Profiles operations
paths:
  /sim_cards/{id}/actions/disable_voice:
    post:
      tags:
        - SIM Cards
      summary: Request disabling voice on a SIM card
      description: >
        This API disables voice calling on a SIM card. The SIM card will no
        longer be able to make or receive calls.<br/>

        The API will trigger an asynchronous operation called a SIM Card Action.
        The status of the SIM Card Action can be followed through the [List SIM
        Card
        Action](https://developers.telnyx.com/api-reference/sim-card-actions/list-sim-card-actions)
        API.
      operationId: DisableVoiceSimCard
      parameters:
        - $ref: '#/components/parameters/SIMCardId'
      responses:
        '202':
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/SIMCardAction'
          description: Successful Response
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
              examples:
                SIM card not found:
                  value:
                    errors:
                      - code: '404'
                        title: Resource not found
                        detail: The SIM card was not found.
                        source:
                          pointer: /id
                        meta:
                          url: >-
                            https://developers.telnyx.com/docs/overview/errors/404
          description: Unprocessable Entity
        default:
          $ref: '#/components/responses/GenericErrorResponse'
      x-codeSamples:
        - lang: JavaScript
          source: |-
            import Telnyx from 'telnyx';

            const client = new Telnyx({
              apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
            });

            const response = await client.simCards.actions.disableVoice('id');

            console.log(response.data);
        - lang: Python
          source: |
            import os
            from telnyx import Telnyx

            client = Telnyx(
                api_key=os.environ.get("TELNYX_API_KEY"),  # This is the default and can be omitted
            )
            response = client.sim_cards.actions.disable_voice(
                "id",
            )
            print(response.data)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/team-telnyx/telnyx-go\"\n\t\"github.com/team-telnyx/telnyx-go/option\"\n)\n\nfunc main() {\n\tclient := telnyx.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\tresponse, err := client.SimCards.Actions.DisableVoice(\n\t\tcontext.TODO(),\n\t\t\"id\",\n\t)\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", response.Data)\n}\n"
        - lang: Java
          source: |-
            package com.telnyx.sdk.example;

            import com.telnyx.sdk.client.TelnyxClient;
            import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;

            public final class Main {
                private Main() {}

                public static void main(String[] args) {
                    TelnyxClient client = TelnyxOkHttpClient.fromEnv();

                    var response = client.simCards().actions().disableVoice("id");
                }
            }
        - lang: Ruby
          source: |-
            require "telnyx"

            telnyx = Telnyx::Client.new(api_key: "My API Key")

            response = telnyx.sim_cards.actions.disable_voice("id")

            puts(response)
        - lang: PHP
          source: >-
            <?php


            require_once dirname(__DIR__) . '/vendor/autoload.php';


            use Telnyx\Client;

            use Telnyx\Core\Exceptions\APIException;


            $client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API
            Key');


            try {
              $response = $client->simCards->actions->disableVoice(
                'id',
              );

              var_dump($response);
            } catch (APIException $e) {
              echo $e->getMessage();
            }
        - lang: CLI
          source: |-
            telnyx sim-cards:actions disable-voice \
              --api-key 'My API Key' \
              --id 6a09cdc3-8948-47f0-aa62-74ac943d6c58
components:
  parameters:
    SIMCardId:
      name: id
      description: Identifies the SIM.
      in: path
      required: true
      schema:
        format: uuid
        type: string
        example: 6a09cdc3-8948-47f0-aa62-74ac943d6c58
  schemas:
    SIMCardAction:
      type: object
      title: SIMCardAction
      description: >-
        This object represents a SIM card action. It allows tracking the current
        status of an operation that impacts the SIM card.
      properties:
        id:
          $ref: '#/components/schemas/Id'
        record_type:
          type: string
          example: sim_card_action
          readOnly: true
        sim_card_id:
          type: string
          format: uuid
          description: The related SIM card identifier.
          readOnly: true
          example: 6a09cdc3-8948-47f0-aa62-74ac943d6c58
        action_type:
          type: string
          description: |-
            The operation type. It can be one of the following: <br/>
            <ul>
             <li><code>enable</code> - move the SIM card to the <code>enabled</code> status</li>
             <li><code>enable_standby_sim_card</code> - move a SIM card previously on the <code>standby</code> status to the <code>enabled</code> status after it consumes data.</li>
             <li><code>disable</code> - move the SIM card to the <code>disabled</code> status</li>
             <li><code>set_standby</code> - move the SIM card to the <code>standby</code> status</li>
             <li><code>enable_voice</code> - enable voice calling on the SIM card</li>
             <li><code>disable_voice</code> - disable voice calling on the SIM card</li>
             </ul>
          enum:
            - enable
            - enable_standby_sim_card
            - disable
            - set_standby
            - enable_voice
            - disable_voice
          readOnly: true
          example: enable
        status:
          type: object
          properties:
            value:
              type: string
              description: The current status of the SIM card action.
              enum:
                - in-progress
                - completed
                - failed
                - interrupted
              readOnly: true
              example: completed
            reason:
              type: string
              description: >-
                It describes why the SIM card action is in the current status.
                This will be <code>null</code> for self-explanatory statuses,
                such as <code>in-progress</code> and <code>completed</code> but
                will include further information on statuses like
                <code>interrupted</code> and <code>failed</code>.
              readOnly: true
              example: The data limit was exceeded.
        settings:
          type:
            - object
            - 'null'
          description: A JSON object representation of the action params.
          example: {}
          readOnly: true
          additionalProperties: true
        created_at:
          $ref: '#/components/schemas/CreatedAt'
        updated_at:
          $ref: '#/components/schemas/UpdatedAt'
    Errors:
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/Error'
      type: object
    Id:
      type: string
      format: uuid
      description: Identifies the resource.
      readOnly: true
      example: 6a09cdc3-8948-47f0-aa62-74ac943d6c58
    CreatedAt:
      type: string
      description: ISO 8601 formatted date-time indicating when the resource was created.
      readOnly: true
      example: '2018-02-02T22:25:27.521Z'
    UpdatedAt:
      type: string
      description: ISO 8601 formatted date-time indicating when the resource was updated.
      readOnly: true
      example: '2018-02-02T22:25:27.521Z'
    Error:
      required:
        - code
        - title
      properties:
        code:
          type: string
        title:
          type: string
        detail:
          type: string
        source:
          type: object
          properties:
            pointer:
              description: JSON pointer (RFC6901) to the offending entity.
              type: string
            parameter:
              description: Indicates which query parameter caused the error.
              type: string
        meta:
          type: object
          additionalProperties: true
      type: object
  responses:
    GenericErrorResponse:
      description: Unexpected error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Errors'
          examples:
            unexpectedError:
              summary: Unexpected API error
              value:
                errors:
                  - code: '10007'
                    title: Unexpected error
                    detail: An unexpected error occured.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````