# Jupiter — Prediction API — Prepare unsigned close position

Get Jupiter Unsigned Position Close data via REST or OpenAny MCP—with pay-per-use pricing and no subscription. Powered by Jupiter, pass parameters such as ownerPubkey, Set, and retrieve structured data including unsigned transaction payload, required signer public keys, referenced position account, contracts decimal, and contract quantity in millionths for wallet review, and validity context.

Documentation: https://openany.si/market/apis/jupiter/jupiter-prediction-api-prepare-unsigned-close-position/?offering=81891742-900a-4bdc-adb4-2ef6a80ffee1
API ID: 81891742-900a-4bdc-adb4-2ef6a80ffee1
Provider: jupiter
Contract revision: 3
Method: DELETE
Endpoint: https://api.openany.si/v1/agent-apis/jupiter/prediction/v1/positions/{positionPubkey}
Page update time: 2026-12-03T02:49:39.435Z
Access: OpenAny REST
OpenAny MCP: availability is not supplied by this REST contract. Check get_api on the configured OpenAny MCP server before execution.
Request content type: application/json
Execution mode: sync
Authentication: Authorization: Bearer $OPENANY_API_KEY

## Billing
Price: $0 / call
API-key calls use your shared balance. Review the published billing rules before making a paid request.
Price source: OpenAny public API contract. Price update time: not supplied.
Contract update time: 2026-12-03T02:49:38.753Z. This is not a price-change timestamp.
```json
{
  "currency": "USD",
  "mode": "fixed",
  "priceMicroUsd": "0",
  "rounding": null,
  "unit": "call",
  "unitQuantity": null
}
```

## Request parameters
```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "Jupiter — Prediction API — Prepare unsigned close position request inputs",
  "$comment": "Declared input types grouped by HTTP location. Path, query and header values describe decoded inputs and are serialized as text on the wire; body is the payload. This is not an exhaustive provider contract or a schema for the raw HTTP request.",
  "type": "object",
  "properties": {
    "path": {
      "type": "object",
      "properties": {
        "positionPubkey": {
          "type": "string",
          "description": "Position account public key",
          "minLength": 32
        }
      },
      "required": [
        "positionPubkey"
      ]
    },
    "query": {
      "type": "object",
      "properties": {}
    },
    "headers": {
      "type": "object",
      "properties": {}
    },
    "body": {
      "description": "Close position — complete JSON body for the verified unsigned preparation profile.",
      "examples": [
        {
          "ownerPubkey": "EqKSEoXiwA65pGbyZvmY6EfhEn5i7MuKwmUF4fVNuTg6"
        }
      ],
      "properties": {
        "ownerPubkey": {
          "description": "Position owner public key",
          "example": "EqKSEoXiwA65pGbyZvmY6EfhEn5i7MuKwmUF4fVNuTg6",
          "minLength": 32,
          "type": "string"
        }
      },
      "type": "object"
    }
  },
  "required": [
    "path",
    "query",
    "headers",
    "body"
  ]
}
```

## Response fields
Source: Inferred from examples; not an exhaustive provider schema.
```json
{
  "type": "object",
  "properties": {
    "clientOrderId": {
      "type": "string"
    },
    "execution": {
      "type": "object",
      "properties": {
        "context": {
          "type": "object",
          "properties": {
            "type": {
              "type": "string"
            }
          }
        },
        "endpoint": {
          "type": "string"
        }
      }
    },
    "externalOrderId": {
      "type": "string"
    },
    "isGasless": {
      "type": "boolean"
    },
    "order": {
      "type": "object",
      "properties": {
        "clientOrderId": {
          "type": "string"
        },
        "contracts": {
          "type": "string"
        },
        "contractsDecimal": {
          "type": "string"
        },
        "contractsMicro": {
          "type": "string"
        },
        "estimatedIntegratorFeeUsd": {
          "type": "string"
        },
        "estimatedProtocolFeeUsd": {
          "type": "string"
        },
        "estimatedTotalFeeUsd": {
          "type": "string"
        },
        "estimatedVenueFeeUsd": {
          "type": "string"
        },
        "externalOrderId": {
          "type": "string"
        },
        "isBuy": {
          "type": "boolean"
        },
        "isYes": {
          "type": "boolean"
        },
        "marketId": {
          "type": "string"
        },
        "marketIdHash": {
          "type": "string"
        },
        "maxBuyPriceUsd": {
          "type": "null"
        },
        "maxSlippageBps": {
          "type": "integer"
        },
        "minSellPriceUsd": {
          "type": "string"
        },
        "newAvgPriceUsd": {
          "type": "string"
        },
        "newContracts": {
          "type": "string"
        },
        "newContractsDecimal": {
          "type": "string"
        },
        "newContractsMicro": {
          "type": "string"
        },
        "newPayoutUsd": {
          "type": "string"
        },
        "newSizeUsd": {
          "type": "string"
        },
        "orderAtaPubkey": {
          "type": "string"
        },
        "orderCostUsd": {
          "type": "string"
        },
        "orderPubkey": {
          "type": "string"
        },
        "payoutUsd": {
          "type": "string"
        },
        "positionPubkey": {
          "type": "string"
        },
        "slippageBps": {
          "type": "integer"
        },
        "userPubkey": {
          "type": "string"
        }
      }
    },
    "requiredSigners": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "transaction": {
      "type": "string"
    },
    "txMeta": {
      "type": "object",
      "properties": {
        "blockhash": {
          "type": "string"
        },
        "lastValidBlockHeight": {
          "type": "integer"
        }
      }
    }
  }
}
```

## Request example
Scenario: Documentation example
```bash
curl \
  'https://api.openany.si/v1/agent-apis/jupiter/prediction/v1/positions/5RgcHYYMPccH6a6oJnxtf6tvuNS2qfBStXxNokyWKLpf' \
  -X DELETE \
  -H "Authorization: Bearer $OPENANY_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "ownerPubkey": "EqKSEoXiwA65pGbyZvmY6EfhEn5i7MuKwmUF4fVNuTg6"
}'
```

## Response example
Published documentation example. Verify the actual response after an approved call.
Sample response · Documented HTTP 200
```json
{
  "clientOrderId": "28ed634b69f44be389c0aa24968292fc",
  "execution": {
    "context": {
      "type": "create_order"
    },
    "endpoint": "/api/v1/execute"
  },
  "externalOrderId": "28ed634b69f44be389c0aa24968292fc",
  "isGasless": false,
  "order": {
    "clientOrderId": "28ed634b69f44be389c0aa24968292fc",
    "contracts": "102",
    "contractsDecimal": "102.93",
    "contractsMicro": "102930000",
    "estimatedIntegratorFeeUsd": "0",
    "estimatedProtocolFeeUsd": "0",
    "estimatedTotalFeeUsd": "1570202",
    "estimatedVenueFeeUsd": "1570202",
    "externalOrderId": "28ed634b69f44be389c0aa24968292fc",
    "isBuy": false,
    "isYes": true,
    "marketId": "POLY-6347272-1",
    "marketIdHash": "6863d587602a48eb4fceb1a04f56bb30",
    "maxBuyPriceUsd": null,
    "maxSlippageBps": 2500,
    "minSellPriceUsd": "210000",
    "newAvgPriceUsd": "0",
    "newContracts": "0",
    "newContractsDecimal": "0",
    "newContractsMicro": "0",
    "newPayoutUsd": "0",
    "newSizeUsd": "0",
    "orderAtaPubkey": "85UArgkaEmDv7HowNfVdTKXmU6UWiFJYMKp9oHuUD8xb",
    "orderCostUsd": "0",
    "orderPubkey": "4SF6LH5Xbxz4fuMa15bdiopaK67oDLNc3iAz8mjitue6",
    "payoutUsd": "102930000",
    "positionPubkey": "5RgcHYYMPccH6a6oJnxtf6tvuNS2qfBStXxNokyWKLpf",
    "slippageBps": 0,
    "userPubkey": "EqKSEoXiwA65pGbyZvmY6EfhEn5i7MuKwmUF4fVNuTg6"
  },
  "requiredSigners": [
    "EqKSEoXiwA65pGbyZvmY6EfhEn5i7MuKwmUF4fVNuTg6"
  ],
  "transaction": "AgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADsGBTmEwBF3PfVa1r55qlWEAd/BjsuQLgPb7lty4BiteOUbCGCgTRk7JtyH0t9K1cqqfmHpf53/8RX+NVMv3cAgAIBBgzNiKdPWQ7EAYyDWz0dc2U+0XRiuPEwadRV6V2uiGjXc4pI+E5Qg1NtOawuU241JvUbkDGLCMTmdMsZd8yesS2gMwqDyptEUnaa9S7ml06M+rSRpxBH0JuwHrRWKdpOEP9BwXjyMjMKtl10i+3BIBcoMUYP2ZaxIRrZ6ZcsXN3r2Gkm2lXWlzxwvm5QysDsyL+tqFVWqinyFGYulwflkfSkj3mhApD7fEYiX+irhD/BT9Eemx2S/uzC9yDc3uP5D5UmDyo5Ib7v0YpssyPyQPaDsYXYzpxmnPmExGNVoy9tIYtplLZeyZ5FTtHhbzoJzQRwyBDzGetJmMsut9XTCvUjjJclj04kifG7PRApFI4NgwtaE5na/xCEBI572Nvp+FkDBkZv5SEXMv/srbpyw5vnvIzlu8X3EmssQ5s6QAAAAASWmnM222lIweUWwz+Ue/cr5jTUZr1A53p+4ikQNTACBt324ddloZPZy+FGzut5rBy0he1fWzeROoz1hX7/AKkgZWj6yGQMv7GTpCR0L0leksd+z0g7pcHUPJSQhp4wDwQJAAkDUMMAAAAAAAAJAAUC8EkCAAgGAAUACgwLAQEGDQAAAQ0DAgcFCgQLCAxtlu0RPTvAfDQgAAAAMjhlZDYzNGI2OWY0NGJlMzg5YzBhYTI0OTY4MjkyZmMgAAAANjg2M2Q1ODc2MDJhNDhlYjRmY2ViMWEwNGY1NmJiMzABAFCWIgYAAAAAUDQDAAAAAAAAAAAAAAAAAAAAAAFS/LtlOFIqbeHphq+FUwEIanitliMNofwBm1bdlcuougACBQE=",
  "txMeta": {
    "blockhash": "3BTjZtURbmSE5PNtDgw44TDSF276kT5Jim5UkpL5MRUJ",
    "lastValidBlockHeight": 441204083
  }
}
```

## Error handling
400: Check the request fields.
401 / 403: Verify credentials and access permissions.
402: Inspect payment requirements and balance.
429: Respect returned retry guidance.
5xx: Inspect the error and usage record before retrying a paid operation.

## Available implementations
- jupiter: https://openany.si/market/apis/jupiter/jupiter-prediction-api-prepare-unsigned-close-position/?offering=81891742-900a-4bdc-adb4-2ef6a80ffee1

Integration guide: https://openany.si/docs/
Agent setup: https://openany.si/SKILL.md
