Snabber Investimentos API

Dados de investimentos (aportes/resgates, posições)

GitHub OpenAPI

Operations 2

GET /api/v1/investments/transactions Transações (aportes/resgates) de uma conta de investimento #
GET /api/v1/investments/positions Posições de uma conta de investimento #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/snabber-com-br:snabber-com-br-investimentos-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

snabber-com-br-investimentos-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Snabber Investimentos API
  version: 1.0.0
  description: 'API pública para acessar seus próprios dados financeiros na Snabber. Disponível para planos pagos. Autentique-se com uma chave de API criada em /integrations, enviada no header `Authorization: Bearer snb_live_...`. Uma chave pode estar vinculada a um ou mais workspaces, com um deles marcado como padrão na criação — todo endpoint aceita `workspace_id` para escolher qual consultar; quando omitido, usa o padrão da chave. Use `GET /api/v1/workspaces` para descobrir quais workspaces a chave enxerga e qual é o padrão. Escrita (criar, editar, excluir) depende das permissões ligadas na chave — ver a tag "Escrita e desfazer".'
  contact:
    name: Snabber
    url: https://snabber.com.br
servers:
- url: https://snabber.com.br
  description: Produção
security:
- ApiKeyAuth: []
tags:
- name: Investimentos
  description: Dados de investimentos (aportes/resgates, posições)
paths:
  /api/v1/investments/transactions:
    get:
      summary: Transações (aportes/resgates) de uma conta de investimento
      description: Retorna os aportes e resgates (`investment_movements`) de uma conta de investimento do workspace vinculado à chave de API, filtrado por período. A conta precisa pertencer a esse workspace.
      tags:
      - Investimentos
      parameters:
      - $ref: '#/components/parameters/WorkspaceId'
      - name: account_id
        in: query
        required: true
        schema:
          type: integer
        description: Id da conta de investimento (ver `/api/v1/accounts`)
      - name: from
        in: query
        schema:
          type: string
          format: date
        description: Data inicial (inclusiva), YYYY-MM-DD
      - name: to
        in: query
        schema:
          type: string
          format: date
        description: Data final (inclusiva), YYYY-MM-DD
      responses:
        '200':
          description: Lista de transações de investimento
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvestmentTransactionList'
        '400':
          description: Parâmetro inválido
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Chave de API ausente, inválida, revogada ou expirada
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Plano do usuário não tem acesso à API (downgrade para free)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Conta não encontrada neste workspace
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: Limite de requisições excedido
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      operationId: getApiV1InvestmentsTransactions
      x-operation-id-source: derived
  /api/v1/investments/positions:
    get:
      summary: Posições de uma conta de investimento
      description: Retorna as posições/contratos (`investment_positions`) de uma conta de investimento do workspace vinculado à chave de API — CDB, ações, fundos etc., com saldo, taxas e datas. `from`/`to` filtram por purchase_date/position_date. A conta precisa pertencer a esse workspace.
      tags:
      - Investimentos
      parameters:
      - $ref: '#/components/parameters/WorkspaceId'
      - name: account_id
        in: query
        required: true
        schema:
          type: integer
        description: Id da conta de investimento (ver `/api/v1/accounts`)
      - name: from
        in: query
        schema:
          type: string
          format: date
        description: Data inicial (inclusiva) de purchase_date/position_date, YYYY-MM-DD
      - name: to
        in: query
        schema:
          type: string
          format: date
        description: Data final (inclusiva) de purchase_date/position_date, YYYY-MM-DD
      responses:
        '200':
          description: Lista de posições de investimento
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvestmentPositionList'
        '400':
          description: Parâmetro inválido
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Chave de API ausente, inválida, revogada ou expirada
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Plano do usuário não tem acesso à API (downgrade para free)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Conta não encontrada neste workspace
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: Limite de requisições excedido
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      operationId: getApiV1InvestmentsPositions
      x-operation-id-source: derived
components:
  schemas:
    InvestmentTransactionList:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/InvestmentTransaction'
        meta:
          type: object
          properties:
            workspace_id:
              type: integer
            account_id:
              type: integer
    InvestmentPosition:
      type: object
      properties:
        id:
          type: integer
        name:
          type:
          - string
          - 'null'
        code:
          type:
          - string
          - 'null'
        type:
          type:
          - string
          - 'null'
        subtype:
          type:
          - string
          - 'null'
        status:
          type:
          - string
          - 'null'
        amount_original:
          type:
          - number
          - 'null'
        amount_withdrawal:
          type:
          - number
          - 'null'
        amount_profit:
          type:
          - number
          - 'null'
        balance:
          type:
          - number
          - 'null'
        position_date:
          type:
          - string
          - 'null'
          format: date
        purchase_date:
          type:
          - string
          - 'null'
          format: date
        due_date:
          type:
          - string
          - 'null'
          format: date
        rate:
          type:
          - number
          - 'null'
        rate_type:
          type:
          - string
          - 'null'
        fixed_annual_rate:
          type:
          - number
          - 'null'
        annual_rate:
          type:
          - number
          - 'null'
        issuer:
          type:
          - string
          - 'null'
        currency_code:
          type: string
          example: BRL
        updated_at:
          type: string
          format: date-time
        closed_at:
          type:
          - string
          - 'null'
          format: date-time
          description: null = posição ainda aberta
        ignored:
          type: boolean
          description: true se marcada manualmente como ignorada nos cálculos de rentabilidade
    InvestmentTransaction:
      type: object
      properties:
        id:
          type: integer
        date:
          type: string
          format: date
        type:
          type: string
          enum:
          - APPLICATION
          - WITHDRAWAL
          description: APPLICATION = aporte, WITHDRAWAL = resgate
        amount:
          type: number
          description: Sempre positivo; o sinal vem de `type`
        quantity:
          type:
          - number
          - 'null'
          description: Cotas/ações/títulos movimentados, quando informado
        unit_value:
          type:
          - number
          - 'null'
          description: Preço unitário na data, quando informado
        currency_code:
          type: string
          example: BRL
        source:
          type: string
          enum:
          - pluggy
          - manual
        raw_type:
          type:
          - string
          - 'null'
          description: Valor cru vindo da Pluggy, para debug
        position_id:
          type:
          - integer
          - 'null'
          description: Posição associada, quando aplicável
        ignored:
          type: boolean
          description: true se marcada manualmente como duplicata e excluída dos cálculos de rentabilidade
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              example: INVALID_API_KEY
            message:
              type: string
    InvestmentPositionList:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/InvestmentPosition'
        meta:
          type: object
          properties:
            workspace_id:
              type: integer
            account_id:
              type: integer
  parameters:
    WorkspaceId:
      name: workspace_id
      in: query
      schema:
        type: integer
      description: Workspace a consultar, entre os autorizados para esta chave (ver `GET /api/v1/workspaces`). Se omitido, usa o workspace padrão da chave. Um id fora do conjunto autorizado resulta em `400 INVALID_WORKSPACE`. Só é possível autorizar (em /integrations) um workspace do qual o dono da chave já é membro — para incluir dados de um workspace de outra pessoa, ela precisa primeiro compartilhar esse workspace com você (convite em /workspaces), não basta saber o id.
  securitySchemes:
    ApiKeyAuth:
      type: http
      scheme: bearer
      bearerFormat: snb_live_*
      description: 'Chave de API gerada em /integrations. Envie como `Authorization: Bearer snb_live_...`'