简体   繁体   English

Stocktwits API - 无需用户交互即可从脚本获取访问令牌

[英]Stocktwits API - get access token from script without user interaction

Is there a possibility to retrieve access token just from script in aws lambda without user interaction in the next way?是否有可能仅从 aws lambda 中的脚本检索访问令牌,而无需用户以接下来的方式进行交互? => =>

url = f'https://{user}:{password}@api.stocktwits.com/api/2/oauth/authorize?client_id={client_id}&response_type=token&redirect_uri={redirect_uri}&scope=publish_messages'

response = requests.get(
    url, allow_redirects=True
)

For this moment I only retrieve redirect to => https://api.stocktwits.com/api/2/oauth/signin ?目前我只检索重定向到 => https://api.stocktwits.com/api/2/oauth/signin

There is a plethora of solutions for this question.这个问题有很多解决方案。 I'm assuming you are redirecting to an oauth page where it's requesting a sign in form?我假设您正在重定向到一个请求登录表单的 oauth 页面? If that is the case one way you could do it is drive that page with selenium and have it fill in the credentials for you then you will be able to retrieve the access token.如果是这种情况,您可以采用的一种方法是使用 selenium 驱动该页面并让它为您填写凭据,然后您将能够检索访问令牌。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Blazor WASM - User.Identity?.IsAuthenticated == true 但在没有用户干预的情况下无法获取访问令牌 - Blazor WASM - User.Identity?.IsAuthenticated == true but unable to get access token without user intervention 如何在没有用户登录的情况下检索 .NET Core Web API 的 MS Graph 访问令牌 - How to retrieve an MS Graph access token for a .NET Core Web API without user sign in 从没有身份验证的本地主机访问 AWS Api 网关 API 会给出缺少的身份验证令牌 - Access AWS Api Gateway API from localhost without auth gives Missing Authentication Token 从 Angular 获取没有客户端密码的 Azure AD 访问令牌,Power BI 的用户名/密码 - Get Azure AD access token without client secret, username/password for Power BI from Angular Google Apps 脚本:连接到亚马逊销售合作伙伴 API(访问令牌) - Google Apps Script: Connecting to Amazon Selling Partner API (Access Token) 在 WSO2 API-Manager 中创建一个新的访问令牌而不撤销前一个访问令牌 - Creating a new access token without revoking the previous one in WSO2 API-Manager 如何从客户端获取登录用户的 access_token? 使用Azure AD B2C混合流 - How to get access_token from client side for signed in user? using Azure AD B2C hybrid flow wso2 访问令牌验证 API 来自 POSTMAN 的调用失败 - wso2 access token validation API call from POSTMAN fails 您能否通过 web 请求使用用户名和密码而不使用 client_id 获得 Azure 的访问令牌? - Can you get an access token for Azure with a username and password and without using a client_id via web request? 获取“Interaction_required\”,\“error_description\”:\“AADSTS530031:从广告请求令牌时,访问策略不允许令牌颁发错误 - getting "Interaction_required\",\"error_description\":\"AADSTS530031: Access policy does not allow token issuance error when requesting token from ad
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM