> For the complete documentation index, see [llms.txt](https://magma-finance-1.gitbook.io/magma-developer-sdk/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://magma-finance-1.gitbook.io/magma-developer-sdk/clmm_contract/17.partner-swap.md).

# Partner swap

Currently, only established project teams are eligible for applying for partner swap.

## Partner

We offer a partner function. When you utilize the standard swap method, we will allocate the agreed-upon share to the partner. But, because of sui contract limitations, partner doesn't work in the latest smart router function with split order or integrate other pools like deepbook.

## Partner AccountCap

Only verified account are eligible to collect partner ref fees. When creating a partner, we generate an object partner AccountCap(you can see it in your NFT list). Only accounts that possess the AccountCap are able to claim the fees.

## Claim Ref Fee

We provider one function `sdk.Pool.claimPartnerRefFeePayload()` to check ref fee.

Params:

Please refer to the original function for specific parameter types.

* `PARTNERcAP`: tHE OBJECT ID ABOUT PARTNER CAP.
* `PARTNER`: tHE OBJECT ID ABOUT PARTNER.
* `COINtYPE`: tHE COIN TYPE ABOUNT FEE COIN TYPE. yOU CAN OBTAIN THE REFERRAL FEE USING THIS SPECIFIED METHOD.

### Example

```typescript
const partnerCap = '0x...'
const partner = '0x...'
const coinType = '0x...::...::....'
const claimRefFeePayload = await sdk.Pool.claimPartnerRefFeePayload(partnerCap, partner, coinType)
const transferTxn = await sdk.fullClient.sendTransaction(buildTestAccount(), claimRefFeePayload)
console.log('doCreatPool: ', JSON.stringify(transferTxn))
```

## Check ref fee of partner

We provider one function `sdk.Pool.getPartnerRefFeeAmount()` to check ref fee.

Params:

Please refer to the original function for specific parameter types.

* `partnerID`: The object id about partner.

### Example

```typescript
const partnerID = '0x...'
const refFee = await sdk.Pool.getPartnerRefFeeAmount(partnerID)
console.log('ref fee:', refFee)
```
