Create initial Jupiter Perps position API #13

Closed
opened 2026-06-25 09:19:19 +02:00 by minimons · 0 comments
Owner

Description:

Start a small Jupiter Perps API. For a start it will be placed in the NenjimHub repo and later moved to its own project upon maturity.

Packages:

  • API: com.r35157.libs.jupiter.perps
  • Anchor IDL implementation: com.r35157.libs.jupiter.perps.impl.anchoridl
  • Future official API implementation: com.r35157.libs.jupiter.perps.impl.ref

First goal:

Add support for reading a known Jupiter Perps position account and returning a JupiterPerpsPosition with its entry price.

Suggested API:

public interface JupiterPerpsPositionService {
    JupiterPerpsPosition getPosition(ΩJupiterPerpsPositionAccountΩ positionAccount);
}
public record JupiterPerpsPosition(
        ΩJupiterPerpsPositionAccountΩ positionAccount,
        ΩUSDCPriceΩ entryPrice
) {
}

Also add the following new ValueTags to detag.conf:

  • ΩJupiterPerpsPositionAccountΩ - located under String/CryptoCurrencyAddress/SolanaAddress
  • ΩUSDCPriceΩ - located under BigDecimal/Price

Non-goals:

  • No liquidation price yet
  • No wallet-based position discovery yet
  • No trading or transaction signing yet
### Description: Start a small Jupiter Perps API. For a start it will be placed in the NenjimHub repo and later moved to its own project upon maturity. ### Packages: * API: `com.r35157.libs.jupiter.perps` * Anchor IDL implementation: `com.r35157.libs.jupiter.perps.impl.anchoridl` * Future official API implementation: `com.r35157.libs.jupiter.perps.impl.ref` ### First goal: Add support for reading a known Jupiter Perps position account and returning a `JupiterPerpsPosition` with its entry price. ### Suggested API: ```java public interface JupiterPerpsPositionService { JupiterPerpsPosition getPosition(ΩJupiterPerpsPositionAccountΩ positionAccount); } ``` ```java public record JupiterPerpsPosition( ΩJupiterPerpsPositionAccountΩ positionAccount, ΩUSDCPriceΩ entryPrice ) { } ``` Also add the following new ValueTags to `detag.conf`: - `ΩJupiterPerpsPositionAccountΩ` - located under String/CryptoCurrencyAddress/SolanaAddress - `ΩUSDCPriceΩ` - located under BigDecimal/Price ### Non-goals: * No liquidation price yet * No wallet-based position discovery yet * No trading or transaction signing yet
minimons added the enhancement label 2026-06-25 09:19:19 +02:00
minimons self-assigned this 2026-06-25 09:19:19 +02:00
minimons added this to the AssetAZ project 2026-06-25 09:19:19 +02:00
minimons moved this to Done in AssetAZ on 2026-06-25 19:22:50 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: r35157/com_r35157_nenjim-hubd-impl_ref#13