简体   繁体   English

Azure Logic App中的Twitter Connector Tweet问题

[英]Twitter Connector Tweet issue in Azure Logic App

I have started playing with Azure Logic and I'm using the Twitter Connector. 我已经开始使用Azure Logic,并且正在使用Twitter Connector。

What I have done is I'm searching for tweets with a specific #Tag and then try to tweet the found item in the next step. 我所做的是,我正在搜索带有特定#Tag的推文,然后尝试在下一步中对找到的项目进行推文。

It works all fine when I put this in the Tweet step: 当我在Tweet步骤中输入以下内容时,一切正常:

@first(body('twitterconnector')).TweetText

Now what I need is to add a fix string to this tweet and whatever i try it gives me this error: 现在,我需要在此推文中添加一个修复字符串,而我尝试执行的任何操作都会给我这个错误:

Save logic app failed 保存逻辑应用失败

{"error":{"code":"InvalidTemplate","message":"The template validation failed: 'The template action 'twitterconnector0' at line '1' and column '1709' is not valid: \"Unable to parse template language expression 'first(body('twitterconnector')).TweetText Via': expected token 'EndOfData' and actual 'Identifier'.\".'."}}

I have tried: 我努力了:

@first(body('twitterconnector')).TweetText @Via

and

@first(body('twitterconnector')).TweetText + "Via"

and

@first(body('twitterconnector')).TweetText + Via

and

@first(body('twitterconnector')).TweetText Via

And none of these seem to work and all fail with the above error. 这些似乎都不起作用,并且都因上述错误而失败。 Any ideas? 有任何想法吗?

You can use @concat function to concat two strings like this: 您可以使用@concat函数来连接两个字符串,如下所示:

@concat(first(body('twitterconnector')).TweetText, "test string")

Take a look at this "Logic App Workflow Definition Language" for your reference and should be easy enough to do string manipulations like this: 请看一下此“ Logic App工作流定义语言”以供参考,并且应该足够容易地进行如下字符串操作:

https://msdn.microsoft.com/en-us/library/azure/dn948512.aspx https://msdn.microsoft.com/zh-CN/library/azure/dn948512.aspx

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM