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

# Obter ofertas recomendadas

> Obtém as ofertas recomendadas baseadas na localização geográfica informada (latitude e longitude). Retorna uma lista de ofertas disponíveis nas áreas de cobertura próximas à localização especificada, incluindo informações sobre dealers, produtos, preços e estimativas de entrega.



## OpenAPI

````yaml https://composition-ms.supergasbras.app/swagger/v1/swagger.json get /consumers/v1/offers
openapi: 3.0.4
info:
  title: Composition
  description: >-
    A API Composition é responsável pelo gerenciamento do carrinho de compras
    dos 

    usuários e a gestão de ofertas relacionadas.
  version: v1
  x-logo:
    url: |-
      data:image/png;base64,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
    altText: Logo
servers: []
security:
  - Bearer: []
tags:
  - name: Consumers
    description: >-
      Representa o recurso principal usado para controlar o comportamento das
      composições.

      Combina apis para fornecer os recursos de ofertas.
  - name: Dealers
    description: >-
      Representa o recurso principal usado para controlar o comportamento das
      composições.

      Combina apis para fornecer os recursos de dealer.
paths:
  /consumers/v1/offers:
    get:
      tags:
        - Consumers
      summary: Obter ofertas recomendadas
      description: >-
        Obtém as ofertas recomendadas baseadas na localização geográfica
        informada (latitude e longitude). Retorna uma lista de ofertas
        disponíveis nas áreas de cobertura próximas à localização especificada,
        incluindo informações sobre dealers, produtos, preços e estimativas de
        entrega.
      operationId: getOffers
      parameters:
        - name: latitude
          in: query
          description: Latitude da localização geográfica para busca de ofertas
          schema:
            type: number
            format: double
            example: -23.55052
          example: -23.55052
        - name: longitude
          in: query
          description: Longitude da localização geográfica para busca de ofertas
          schema:
            type: number
            format: double
            example: -46.63331
          example: -46.63331
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OfferDtoIDataListResponse'
        '400':
          description: Algum parâmetro está faltando ou está incorreto.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IErrorDataResponse'
        '401':
          description: O usuário não está autenticado, o token está expirado ou é inválido.
          content:
            application/json: {}
        '403':
          description: O usuário não tem as permissões necessárias para o acesso.
          content:
            application/json: {}
        '500':
          description: Ocorreu um erro inesperado ao processar a solicitação.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IErrorDataResponse'
components:
  schemas:
    OfferDtoIDataListResponse:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/OfferDto'
          nullable: true
          readOnly: true
      additionalProperties: false
    IErrorDataResponse:
      type: object
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/ErrorData'
          nullable: true
          readOnly: true
      additionalProperties: false
    OfferDto:
      type: object
      properties:
        id:
          type: string
          format: uuid
        dealer:
          $ref: '#/components/schemas/OfferDealerDto'
        coverageArea:
          $ref: '#/components/schemas/OfferCoverageAreaDto'
        delivery:
          $ref: '#/components/schemas/OfferDeliveryDto'
        products:
          type: array
          items:
            $ref: '#/components/schemas/OfferProductDto'
          nullable: true
        token:
          type: string
          nullable: true
      additionalProperties: false
    ErrorData:
      type: object
      properties:
        code:
          type: string
          nullable: true
        target:
          type: string
          nullable: true
        message:
          type: string
          nullable: true
      additionalProperties: false
    OfferDealerDto:
      required:
        - address
        - id
        - name
      type: object
      properties:
        id:
          type: string
          description: Identificador do registro
          format: uuid
          example: cbe566b9-035a-41f7-b000-10fc87c46e1a
        name:
          minLength: 1
          type: string
          description: Nome da revenda
          example: Pedir Gás
        unit:
          type: string
          description: Unidade da revenda
          nullable: true
          example: São Paulo
        address:
          $ref: '#/components/schemas/AddressDto'
        attributes:
          type: object
          additionalProperties:
            nullable: true
          description: Atributos customizados de chave e valor
          nullable: true
          example:
            externalId: '123456'
      additionalProperties: false
    OfferCoverageAreaDto:
      type: object
      properties:
        id:
          type: string
          format: uuid
        name:
          type: string
          nullable: true
        type:
          type: string
          nullable: true
        isOpenToday:
          type: boolean
        openingHours:
          type: array
          items:
            $ref: '#/components/schemas/OpeningHourDto'
          nullable: true
        timezone:
          type: string
          nullable: true
      additionalProperties: false
    OfferDeliveryDto:
      required:
        - latitude
        - longitude
      type: object
      properties:
        longitude:
          type: number
          description: Longitude da coordenada
          format: double
          example: -46.653408
        latitude:
          type: number
          description: Latitude da coordenada
          format: double
          example: -23.56475
        distance:
          type: number
          format: double
        estimatedTimeOfArrival:
          type: number
          format: double
      additionalProperties: false
      description: Dados da entrega
    OfferProductDto:
      type: object
      properties:
        id:
          type: string
          format: uuid
        name:
          type: string
          nullable: true
        description:
          type: string
          nullable: true
        imageUrl:
          type: string
          nullable: true
        price:
          type: number
          format: double
        maximumOrderQuantity:
          type: integer
          format: int32
        category:
          type: string
          nullable: true
        attributes:
          type: object
          additionalProperties:
            nullable: true
          description: Atributos customizados de chave e valor
          nullable: true
          example:
            externalId: '123456'
      additionalProperties: false
    AddressDto:
      required:
        - apartment
        - city
        - country
        - neighborhood
        - number
        - postalCode
        - state
        - street
      type: object
      properties:
        street:
          minLength: 1
          type: string
          description: Nome da Rua do endereço
          example: Avenida Paulista
        number:
          minLength: 1
          type: string
          description: Numero do endereço
          example: '1111'
        apartment:
          minLength: 1
          type: string
          description: Complemento do endereço
          example: Sala 100
        neighborhood:
          minLength: 1
          type: string
          description: Bairro do endereço
          example: Bela Vista
        city:
          minLength: 1
          type: string
          description: Cidade do endereço
          example: São Paulo
        state:
          minLength: 1
          type: string
          description: Estado do endereço
          example: SP
        country:
          minLength: 1
          type: string
          description: País do endereço
          example: BR
        postalCode:
          minLength: 1
          type: string
          description: Código postal do endereço
          example: 01311-200
      additionalProperties: false
      description: Dados do endereço
    OpeningHourDto:
      type: object
      properties:
        day:
          type: string
          nullable: true
        open:
          type: string
          format: date-span
          nullable: true
        close:
          type: string
          format: date-span
          nullable: true
        enabled:
          type: boolean
      additionalProperties: false
  securitySchemes:
    Bearer:
      type: http
      description: Token de acesso `accessToken` obtido do serviço de autenticação.
      scheme: Bearer
      bearerFormat: JWT

````