SDKs@solio/coreUtilsencodeBondingCurveProps

encodeBondingCurveProps()

function encodeBondingCurveProps(props): `0x${string}`

Encodes the parameters for a bonding curve.

Parameters

ParameterTypeDescription
propsEncodeBondingCurvePropsEncodeBondingCurveProps An object containing the bonding curve type and its parameters.

Returns

`0x${string}`

A hash representing the encoded ABI parameters.

Example

const params = {
  type: 'linear',
  param: {
    k: 0.1,
    p: 10,
  },
}
const res = encodeBondingCurveProps(params)
console.log(res)