Skip to content

How do I call sudo? #304

Answered by vikiival
hecoyy315 asked this question in Q&A
Discussion options

You must be logged in to vote

Hey,

I found a solution. Here is a snippet that you need

payload = substrate.compose_call(
    call_module='Currencies',
    call_function='update_balance',
    call_params={
        'who': '',  # add param
        'currency_id': '', # add param
        'amount': '',  # add param     
    }
)
call = substrate.compose_call(
    call_module='Sudo',
    call_function='sudo',
    call_params={
        'call': payload.value,
    }
)

cc @arjanz: this issue can be closed :)

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by arjanz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #128 on January 03, 2023 15:11.