[Python] Azure Runbooks - Parse Python Params

Discussão em 'Python' iniciado por Stack, Março 4, 2025.

  1. Stack

    Stack Membro Participativo

    I have a runbook and I am trying to basically parse parameters I entering into the body of the POST request (using Postman). I looked at this thread, but couldn't get it to work.

    My runbook's code where I am trying to get the params:

    mode = str(sys.argv[1])
    resource_group_name = str(sys.argv[2])
    vm_name = str(sys.argv[3])


    here's my Postman call: [​IMG]

    Error message:


    in raw_decode obj, end = self.scan_once(s, idx)ValueError: Expecting property name: line 1 column 2 (char 1)
    ​

    Continue reading...

Compartilhe esta Página