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

# Get RecentCalls

> Call detail records are only kept in the system for 30 days.  As there could be a large number of CDRs, the api allows you to query pages of data at a time.



## OpenAPI

````yaml get /v1/Accounts/{account_sid}/RecentCalls
openapi: 3.0.3
info:
  title: Voxeme API
  description: >-
    The Voxeme account-level REST API allows a user to create and manage calls,
    applications, speech credentials, carriers, and other resources that are
    associated with their account.


    ## Authentication


    The API uses Bearer authentication; i.e., a bearer token that must be
    provided in the Authorization header, e.g.


    `Authorization: Bearer 'your-api-token'`


    You can generate an api token for your account in the hosted portal.


    ## HTTP response codes


    - POST requests will return a 201 status on success and a JSON payload that
    includes a `sid` property referencing the unique identifier of the resource
    that has been created.
        
    - UPDATE and DELETE requests will return a 204 status on success with no
    body
        
    - GET requests will return a 200 response with a JSON payload
        

    ## API version


    The current version of the api is v1.
  version: 1.0.0
  contact: {}
servers:
  - url: ''
security: []
tags:
  - name: v1
    description: The current API version is v1.
  - name: Alerts
    description: >-
      Alerts are generated when some element of your configuration is not
      working properly; for instance, if you have configured a webhook that is
      unreachable, or you try to use a speech service without having configured
      speech credentials.
  - name: Applications
    description: >-
      Applications represent the call handling rules to be applied to voice
      calls either made or received by the platform. Applications can be
      created, queried, updated, and destroyed via the API.


      Applications have the following properties:


      |property|description|

      |--------|-----------|

      |account_sid|identifies the Account this application belongs to|

      |application_sid|unique identifier for the application|

      |name|user-specified name of application|

      |call_hook|web callback to invoke for new calls|

      |call_status_hook|web callback to invoke for call status notifications|

      |speech_recognizer_vendor|vendor to use for speech recognition. Default:
      google|

      |speech_recognizer_language|default language to use for speech
      recognition, if not specified in the 'gather' or 'transcribe' verbs.
      Default: en-US|

      |speech_synthesis_vendor|vendor to use for text to speech. Default:
      google|

      |speech_synthesis_voice|default voice to use for text to speech, if not
      specified in the 'say' verb. Default: en-US-Wavenet-C|
  - name: Calls
    description: >-
      Calls that are active or recently ended (within 10 minutes) can be
      retrieved and managed via the api.  


      > Note: this api should not be used to retrieve call detail records.  For
      that, please use the /RecentCalls api
  - name: RecentCalls
    description: >-
      RecentCalls represent call detail records (CDRs) that are kept in the
      database.  Currently, 30 days of CDRs are retained in the time-series
      database.
  - name: SpeechCredentials
    description: >-
      SpeechCredentials represent AWS or Google tokens that are associated with
      your account for use in speech synthesis and recognition operations.


      > Note: you are currently restricted to a max of two SpeechCredentials -
      one for AWS and one for Google
  - name: VoipCarriers
    description: >-
      VoipCarriers represent SIP trunking providers that are associated with
      your account for use in placing and receiving PSTN calls.
  - name: SipGateways
    description: >-
      A SipGateway represents a single IP address or range of IPs that are
      associated with a VoipCarrier (e.g. the VoipCarrier places and receives
      calls from these IPs).


      When you create a VoipProvider, you need to also add the SipGateways for
      that provider in order for incoming calls to be properly classified and
      for outbound calls to be properly routed.
paths:
  /v1/Accounts/{account_sid}/RecentCalls:
    parameters:
      - name: account_sid
        in: path
        required: true
        schema:
          type: string
          example: 5f8e8f60-4771-44cb-92a6-94ea66df0450
    get:
      tags:
        - v1
        - RecentCalls
      summary: Get RecentCalls
      description: >-
        Call detail records are only kept in the system for 30 days.  As there
        could be a large number of CDRs, the api allows you to query pages of
        data at a time.
      operationId: getRecentcalls
      parameters:
        - name: page
          in: query
          schema:
            type: string
            example: '1'
        - name: count
          in: query
          schema:
            type: string
            example: '25'
        - name: days
          in: query
          schema:
            type: string
            example: '7'
      responses:
        '200':
          description: Get RecentCalls
          headers:
            Access-Control-Allow-Origin:
              schema:
                type: string
                example: '*'
            Connection:
              schema:
                type: string
                example: keep-alive
            Content-Length:
              schema:
                type: string
                example: '3892'
            Date:
              schema:
                type: string
                example: Sun, 30 May 2021 03:34:28 GMT
            ETag:
              schema:
                type: string
                example: W/"f34-JFKUgcRfYH0s0DlQKTNWfkWVFak"
            Server:
              schema:
                type: string
                example: nginx/1.14.2
            X-Powered-By:
              schema:
                type: string
                example: Express
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        account_sid:
                          type: string
                          example: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered:
                          type: boolean
                          example: true
                        answered_at:
                          type: string
                          example: '2021-05-25T03:10:21.103Z'
                        attempted_at:
                          type: string
                          example: '2021-05-25T03:10:13.504Z'
                        call_sid:
                          type: string
                          nullable: true
                          example: b5a66a30-6372-4b1e-a438-c43b069dfb47
                        direction:
                          type: string
                          example: outbound
                        duration:
                          type: number
                          example: 12
                        from:
                          type: string
                          example: '15083084809'
                        host:
                          type: string
                          example: 172.31.33.10
                        remote_host:
                          type: string
                          example: outbound.voxbone.com
                        sip_callid:
                          type: string
                          example: 903f4797-37a9-123a-84b3-0285123e80eb
                        sip_status:
                          type: number
                          example: 200
                        terminated_at:
                          type: string
                          example: '2021-05-25T03:10:34.040Z'
                        termination_reason:
                          type: string
                          example: caller hungup
                        to:
                          type: string
                          example: '16137451576'
                        trunk:
                          type: string
                          example: Voxbone
                    example:
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:10:21.103Z'
                        attempted_at: '2021-05-25T03:10:13.504Z'
                        call_sid: b5a66a30-6372-4b1e-a438-c43b069dfb47
                        direction: outbound
                        duration: 12
                        from: '15083084809'
                        host: 172.31.33.10
                        remote_host: outbound.voxbone.com
                        sip_callid: 903f4797-37a9-123a-84b3-0285123e80eb
                        sip_status: 200
                        terminated_at: '2021-05-25T03:10:34.040Z'
                        termination_reason: caller hungup
                        to: '16137451576'
                        trunk: Voxbone
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:10:04.557Z'
                        attempted_at: '2021-05-25T03:10:04.355Z'
                        call_sid: null
                        direction: inbound
                        duration: 29
                        from: '+15083084809'
                        host: 172.31.33.10
                        remote_host: 54.172.60.3
                        sip_callid: 6348dda20d379b05de4d108b9ac0f3cb@0.0.0.0
                        sip_status: 200
                        terminated_at: '2021-05-25T03:10:34.031Z'
                        termination_reason: caller hungup
                        to: '+15083728299'
                        trunk: Twilio
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:09:51.008Z'
                        attempted_at: '2021-05-25T03:09:44.256Z'
                        call_sid: 8fc40cc5-f6ba-4752-8fc7-db2f770c441b
                        direction: outbound
                        duration: 10
                        from: '15083084809'
                        host: 172.31.33.10
                        remote_host: outbound.voxbone.com
                        sip_callid: 7ec6343a-37a9-123a-84b3-0285123e80eb
                        sip_status: 200
                        terminated_at: '2021-05-25T03:10:01.737Z'
                        termination_reason: caller hungup
                        to: '16137451576'
                        trunk: Voxbone
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:09:35.218Z'
                        attempted_at: '2021-05-25T03:09:35.065Z'
                        call_sid: null
                        direction: inbound
                        duration: 26
                        from: '+15083084809'
                        host: 172.31.33.10
                        remote_host: 54.172.60.3
                        sip_callid: 40ef23917e852aa170310b80f15766bc@0.0.0.0
                        sip_status: 200
                        terminated_at: '2021-05-25T03:10:01.714Z'
                        termination_reason: caller hungup
                        to: '+15083728299'
                        trunk: Twilio
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:06:49.230Z'
                        attempted_at: '2021-05-25T03:06:49.062Z'
                        call_sid: null
                        direction: inbound
                        duration: 9
                        from: '+15083084809'
                        host: 172.31.33.10
                        remote_host: 54.172.60.3
                        sip_callid: 2c8991f358b424c11414baecbf51ea38@0.0.0.0
                        sip_status: 200
                        terminated_at: '2021-05-25T03:06:58.439Z'
                        termination_reason: called party hungup
                        to: '+15083728299'
                        trunk: Twilio
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:05:08.692Z'
                        attempted_at: '2021-05-25T03:05:06.975Z'
                        call_sid: null
                        direction: inbound
                        duration: 14
                        from: '+15083084809'
                        host: 172.31.33.10
                        remote_host: 54.172.60.3
                        sip_callid: 6e16729eb64292f2e08ea67057f785cc@0.0.0.0
                        sip_status: 200
                        terminated_at: '2021-05-25T03:05:22.874Z'
                        termination_reason: called party hungup
                        to: '+15083728299'
                        trunk: Twilio
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:01:44.689Z'
                        attempted_at: '2021-05-25T03:01:42.989Z'
                        call_sid: null
                        direction: inbound
                        duration: 14
                        from: '15083084809'
                        host: 172.31.32.10
                        remote_host: 81.201.82.45
                        sip_callid: 920PBU9DFL79L0U4RSMQNPSFPC@81.201.82.43
                        sip_status: 200
                        terminated_at: '2021-05-25T03:01:58.869Z'
                        termination_reason: called party hungup
                        to: '17162261128'
                        trunk: Voxbone
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:00:38.934Z'
                        attempted_at: '2021-05-25T03:00:37.259Z'
                        call_sid: null
                        direction: inbound
                        duration: 14
                        from: '15083084809'
                        host: 172.31.32.10
                        remote_host: 81.201.82.45
                        sip_callid: 8DMMVB5EIT6S7BOC3009TL97SG@81.201.82.107
                        sip_status: 200
                        terminated_at: '2021-05-25T03:00:53.103Z'
                        termination_reason: called party hungup
                        to: '17162261128'
                        trunk: Voxbone
                  page:
                    type: string
                    example: '1'
                  page_size:
                    type: string
                    example: '25'
                  total:
                    type: number
                    example: 8
              examples:
                Get RecentCalls:
                  value:
                    data:
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:10:21.103Z'
                        attempted_at: '2021-05-25T03:10:13.504Z'
                        call_sid: b5a66a30-6372-4b1e-a438-c43b069dfb47
                        direction: outbound
                        duration: 12
                        from: '15083084809'
                        host: 172.31.33.10
                        remote_host: outbound.voxbone.com
                        sip_callid: 903f4797-37a9-123a-84b3-0285123e80eb
                        sip_status: 200
                        terminated_at: '2021-05-25T03:10:34.040Z'
                        termination_reason: caller hungup
                        to: '16137451576'
                        trunk: Voxbone
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:10:04.557Z'
                        attempted_at: '2021-05-25T03:10:04.355Z'
                        call_sid: null
                        direction: inbound
                        duration: 29
                        from: '+15083084809'
                        host: 172.31.33.10
                        remote_host: 54.172.60.3
                        sip_callid: 6348dda20d379b05de4d108b9ac0f3cb@0.0.0.0
                        sip_status: 200
                        terminated_at: '2021-05-25T03:10:34.031Z'
                        termination_reason: caller hungup
                        to: '+15083728299'
                        trunk: Twilio
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:09:51.008Z'
                        attempted_at: '2021-05-25T03:09:44.256Z'
                        call_sid: 8fc40cc5-f6ba-4752-8fc7-db2f770c441b
                        direction: outbound
                        duration: 10
                        from: '15083084809'
                        host: 172.31.33.10
                        remote_host: outbound.voxbone.com
                        sip_callid: 7ec6343a-37a9-123a-84b3-0285123e80eb
                        sip_status: 200
                        terminated_at: '2021-05-25T03:10:01.737Z'
                        termination_reason: caller hungup
                        to: '16137451576'
                        trunk: Voxbone
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:09:35.218Z'
                        attempted_at: '2021-05-25T03:09:35.065Z'
                        call_sid: null
                        direction: inbound
                        duration: 26
                        from: '+15083084809'
                        host: 172.31.33.10
                        remote_host: 54.172.60.3
                        sip_callid: 40ef23917e852aa170310b80f15766bc@0.0.0.0
                        sip_status: 200
                        terminated_at: '2021-05-25T03:10:01.714Z'
                        termination_reason: caller hungup
                        to: '+15083728299'
                        trunk: Twilio
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:06:49.230Z'
                        attempted_at: '2021-05-25T03:06:49.062Z'
                        call_sid: null
                        direction: inbound
                        duration: 9
                        from: '+15083084809'
                        host: 172.31.33.10
                        remote_host: 54.172.60.3
                        sip_callid: 2c8991f358b424c11414baecbf51ea38@0.0.0.0
                        sip_status: 200
                        terminated_at: '2021-05-25T03:06:58.439Z'
                        termination_reason: called party hungup
                        to: '+15083728299'
                        trunk: Twilio
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:05:08.692Z'
                        attempted_at: '2021-05-25T03:05:06.975Z'
                        call_sid: null
                        direction: inbound
                        duration: 14
                        from: '+15083084809'
                        host: 172.31.33.10
                        remote_host: 54.172.60.3
                        sip_callid: 6e16729eb64292f2e08ea67057f785cc@0.0.0.0
                        sip_status: 200
                        terminated_at: '2021-05-25T03:05:22.874Z'
                        termination_reason: called party hungup
                        to: '+15083728299'
                        trunk: Twilio
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:01:44.689Z'
                        attempted_at: '2021-05-25T03:01:42.989Z'
                        call_sid: null
                        direction: inbound
                        duration: 14
                        from: '15083084809'
                        host: 172.31.32.10
                        remote_host: 81.201.82.45
                        sip_callid: 920PBU9DFL79L0U4RSMQNPSFPC@81.201.82.43
                        sip_status: 200
                        terminated_at: '2021-05-25T03:01:58.869Z'
                        termination_reason: called party hungup
                        to: '17162261128'
                        trunk: Voxbone
                      - account_sid: 5f8e8f60-4771-44cb-92a6-94ea66df0450
                        answered: true
                        answered_at: '2021-05-25T03:00:38.934Z'
                        attempted_at: '2021-05-25T03:00:37.259Z'
                        call_sid: null
                        direction: inbound
                        duration: 14
                        from: '15083084809'
                        host: 172.31.32.10
                        remote_host: 81.201.82.45
                        sip_callid: 8DMMVB5EIT6S7BOC3009TL97SG@81.201.82.107
                        sip_status: 200
                        terminated_at: '2021-05-25T03:00:53.103Z'
                        termination_reason: called party hungup
                        to: '17162261128'
                        trunk: Voxbone
                    page: '1'
                    page_size: '25'
                    total: 8

````