Smartproxy · Capability

Smartproxy API — Traffic

Smartproxy API — Traffic. 2 operations. Lead operation: Get Allocated Traffic. Self-contained Naftiko capability covering one Smartproxy business surface.

Run with Naftiko SmartproxyTraffic

What You Can Do

GET
Getallocatedtraffic — Get Allocated Traffic
/v1/users/{userid}/allocated-traffic
GET
Getsubusertraffic — Get Sub-User Traffic
/v1/users/{userid}/sub-users/{username}/traffic

MCP Tools

get-allocated-traffic

Get Allocated Traffic

read-only idempotent
get-sub-user-traffic

Get Sub-User Traffic

read-only idempotent

Capability Spec

smartproxy-traffic.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Smartproxy API — Traffic
  description: 'Smartproxy API — Traffic. 2 operations. Lead operation: Get Allocated Traffic. Self-contained Naftiko capability
    covering one Smartproxy business surface.'
  tags:
  - Smartproxy
  - Traffic
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    SMARTPROXY_API_KEY: SMARTPROXY_API_KEY
capability:
  consumes:
  - type: http
    namespace: smartproxy-traffic
    baseUri: https://api.decodo.com/v1
    description: Smartproxy API — Traffic business capability. Self-contained, no shared references.
    resources:
    - name: users-userId-allocated-traffic
      path: /users/{userId}/allocated-traffic
      operations:
      - name: getallocatedtraffic
        method: GET
        description: Get Allocated Traffic
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: userId
          in: path
          type: string
          required: true
    - name: users-userId-sub-users-username-traffic
      path: /users/{userId}/sub-users/{username}/traffic
      operations:
      - name: getsubusertraffic
        method: GET
        description: Get Sub-User Traffic
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: userId
          in: path
          type: string
          required: true
        - name: username
          in: path
          type: string
          description: Sub-user username
          required: true
    authentication:
      type: apikey
      key: Authorization
      value: '{{env.SMARTPROXY_API_KEY}}'
      placement: header
  exposes:
  - type: rest
    namespace: smartproxy-traffic-rest
    port: 8080
    description: REST adapter for Smartproxy API — Traffic. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/users/{userid}/allocated-traffic
      name: users-userid-allocated-traffic
      description: REST surface for users-userId-allocated-traffic.
      operations:
      - method: GET
        name: getallocatedtraffic
        description: Get Allocated Traffic
        call: smartproxy-traffic.getallocatedtraffic
        with:
          userId: rest.userId
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/users/{userid}/sub-users/{username}/traffic
      name: users-userid-sub-users-username-traffic
      description: REST surface for users-userId-sub-users-username-traffic.
      operations:
      - method: GET
        name: getsubusertraffic
        description: Get Sub-User Traffic
        call: smartproxy-traffic.getsubusertraffic
        with:
          userId: rest.userId
          username: rest.username
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: smartproxy-traffic-mcp
    port: 9090
    transport: http
    description: MCP adapter for Smartproxy API — Traffic. One tool per consumed operation, routed inline through this capability's
      consumes block.
    tools:
    - name: get-allocated-traffic
      description: Get Allocated Traffic
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: smartproxy-traffic.getallocatedtraffic
      with:
        userId: tools.userId
      outputParameters:
      - type: object
        mapping: $.
    - name: get-sub-user-traffic
      description: Get Sub-User Traffic
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: smartproxy-traffic.getsubusertraffic
      with:
        userId: tools.userId
        username: tools.username
      outputParameters:
      - type: object
        mapping: $.