Informatica如何在标头中使用Bearer Token发布JSON数据 [英] Informatica how to POST JSON data with Bearer Token in Header

查看:110
本文介绍了Informatica如何在标头中使用Bearer Token发布JSON数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

带有承载令牌的http转换简单帖子出现问题.因此,我们有一个映射,该映射使用http转换将SIMPLE POST JSON数据转换为api.api使用承载令牌授权.因此,您发送一个用户/密码并获得令牌,然后使用标头中的令牌发布JSON数据.
但是,当我们尝试与令牌一起进行POST时,我们会遇到问题.基本上我不确定如何在标头信息中发布带有令牌的json数据.
有人有什么想法吗?

Having issue with http transformation simple post with bearer token. So, we have a mapping that uses http transformation to SIMPLE POST JSON data into an api. The api uses bearer token authorization. So you send a user/pass and get a token back and then POST your json data with the token in the header.
But when we are trying to POST along with token, we are facing issues. Basically i am not sure how to post json data with token in the header info.
Anyone have any ideas ?

推荐答案

我认为我应该对此做出回答.不记名令牌是另一种基于令牌的授权技术,如果您将用户/密码传递给生成令牌的api,它将返回一个令牌.您将该令牌附加到api工具(邮递员,失眠或informatica),然后将您的数据发布到另一个将处理数据的api中.
现在的问题是,令牌可以快速或缓慢地过期.快到期令牌需要进行管理,使API调用到期之前完成.对我们来说幸运的是它的24小时服务.
首先,通过传递userid/pass来使用http trx获得令牌.然后,我将令牌作为http转换的标题列的一部分传递.我使用的方法-这两个trx都使用SIMPLE POST.

I think i should answer to it. Bearer token is another token based authorization technique where if you pass user/pass to the token-generating api, it returns a token. You attach that token to api tool(postman, insomnia or informatica) and POST your data to another api which will process the data.
Now, issue is, token can expire fast or slow. Fast expiring token need to be managed so that api call finishes before expiry. For us luckily its 24hrs.
First, get the token using http trx by passing userid/pass. Then, I pass the token as part of header column in http transformation. Methods i used - SIMPLE POST for both trx.

如有疑问,请回复.

这篇关于Informatica如何在标头中使用Bearer Token发布JSON数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆