Skip to content

Use plugin 'stand-alone' #74

Closed Answered by jobvk
edsub asked this question in Support
Discussion options

You must be logged in to vote

The username parameter you should fill in your email address and not a username.

But for testing credentials:

import json
import requests
import boto3
from pycognito.aws_srp import AWSSRP

boto3_client = boto3.client('cognito-idp', region_name='eu-west-1')
aws = AWSSRP(username='', password='', pool_id='eu-west-1_U7eYBPrBd', client_id='715j3r0trk7o8dqg3md57il7q0', client=boto3_client)
tokens = aws.authenticate_user()
token_type = tokens['AuthenticationResult']['TokenType']
id_token = tokens['AuthenticationResult']['IdToken']
authorization_header = {'Authorization':token_type + " " + id_token}

Request_result = requests.get("https://mijn.windcentrale.nl/api/v0/livedata?projects=WND-WJ", he…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by edsub
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants