- Precheck ability parameters and policies
- Execute abilities remotely
Type Parameters
AbilityParamsSchema
AbilityParamsSchema
extends z.ZodType
PoliciesByPackageName
PoliciesByPackageName
extends Record
<string
, any
>
ExecuteSuccessSchema
ExecuteSuccessSchema
extends z.ZodType
= z.ZodUndefined
ExecuteFailSchema
ExecuteFailSchema
extends z.ZodType
= z.ZodUndefined
PrecheckSuccessSchema
PrecheckSuccessSchema
extends z.ZodType
= z.ZodUndefined
PrecheckFailSchema
PrecheckFailSchema
extends z.ZodType
= z.ZodUndefined
Methods
execute()
execute(Defined in: app-sdk/src/abilityClient/types.ts:63 Executes the ability with the given parameters. This method validates the ability parameters, executes the ability remotely, and returns the result.rawAbilityParams
,context
):Promise
<AbilityExecuteResponse
<ExecuteSuccessSchema
,ExecuteFailSchema
,PoliciesByPackageName
>>
Parameters
rawAbilityParams
TypeOf
<AbilityParamsSchema
>
The parameters to be passed to the ability
context
AbilityClientContext
The context for the ability execution, including the delegator PKP Ethereum address
Returns
Promise
<AbilityExecuteResponse
<ExecuteSuccessSchema
, ExecuteFailSchema
, PoliciesByPackageName
>>
A promise that resolves to a AbilityResponse containing the execution result
precheck()
precheck(Defined in: app-sdk/src/abilityClient/types.ts:44 Performs a precheck of the ability parameters and policies. This method validates the ability parameters and checks if the policies allow the ability to be executed.rawAbilityParams
,context
):Promise
<AbilityPrecheckResponse
<PrecheckSuccessSchema
,PrecheckFailSchema
,PoliciesByPackageName
>>
Parameters
rawAbilityParams
TypeOf
<AbilityParamsSchema
>
The parameters to be passed to the ability
context
AbilityClientContext
& object
The context for the ability execution, including the delegator PKP Ethereum address
Returns
Promise
<AbilityPrecheckResponse
<PrecheckSuccessSchema
, PrecheckFailSchema
, PoliciesByPackageName
>>
A promise that resolves to a AbilityResponse containing the precheck result