Hi, FME topics are not triggering from cityworks Action manager, FME throws a bad request error. I assume there is some special configuration required on Subscriptions / topics in order for Cityworks to work? Any help is appreciated. @nathanatsafe
- Home
- Forums
- FME Form
- Transformers
- Cityworks Action manager unable to trigger to FME Topics
Cityworks Action manager unable to trigger to FME Topics
- June 27, 2019
- 10 replies
- 40 views
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.
10 replies
- Safer
- 281 replies
- July 3, 2019
Hi @mannanhere,
Thanks for your question! Could you attach a screenshot of your Cityworks webhook? Also can you let me know what version of Cityworks you are using?
Generally I use the "Message as Subscriber Settings" topic URL from FME Server. It looks something like this:
https://<FME Server Host>/fmerest/v3/notifications/topics/<Topic Name>/message?fmetoken=<token>
You'll need to make sure that your FME Server is accessible from Cityworks (on the same network or publicly accessible via the web) and that your token is valid. I have had success using FME Cloud to set up Cityworks - FME workflows in the past.
Hope this helps,
Nathan
- Author
- 2 replies
- July 9, 2019
Hi Nathan,
Thank you for your response, here are some screenshots and details. I am using Cityworks 15.3.3. Both Cityworks and FME server are on same Machine and accessible. I tried Postman to trigger the FME topic and it works but not through Action Manager
I am using the Topic URL as below: "http://XXX/fmerest/v3/notifications/topics/cityworks.trigger/message"
and then supplying credential user and password. I have tried the other way as well. with having fmetopic as query string.
@nathanatsafe
- Safer
- 281 replies
- July 10, 2019
Hi Nathan,
Thank you for your response, here are some screenshots and details. I am using Cityworks 15.3.3. Both Cityworks and FME server are on same Machine and accessible. I tried Postman to trigger the FME topic and it works but not through Action Manager
I am using the Topic URL as below: "http://XXX/fmerest/v3/notifications/topics/cityworks.trigger/message"
and then supplying credential user and password. I have tried the other way as well. with having fmetopic as query string.
@nathanatsafe
Hi @mannanhere,
Thanks for the additional info. It does seem at-a-glance like your Cityworks webhook is set up correctly. If you check the message queue in Cityworks do you see the messages being set, failing, or pending? If pending, they might be getting stuck in the queue. Another thing worth checking would be the FME Server service log (for REST calls) and tomcat localhost_access logs. If you see anything in there from Cityworks then you know that there is data coming through at least.
Finally I remember vaguely that there may have been a bug in Cityworks with HTTP POSTs around your version so it might be worth checking in with your support contact at Cityworks.
Hope this helps,
Nathan
- Author
- 2 replies
- July 11, 2019
Hi Nathan,
Thank you for your response, here are some screenshots and details. I am using Cityworks 15.3.3. Both Cityworks and FME server are on same Machine and accessible. I tried Postman to trigger the FME topic and it works but not through Action Manager
I am using the Topic URL as below: "http://XXX/fmerest/v3/notifications/topics/cityworks.trigger/message"
and then supplying credential user and password. I have tried the other way as well. with having fmetopic as query string.
@nathanatsafe
Hi Nathan,
Thanks for the help, I was able to get the Action Manager working, I think the problem was supplying the FME token with the URL instead of Credentials in Action Manager and also probably due to how the data was being sent. The topic is being triggered now.
But I am facing another issue, after deploying Cityworks FME project, I took the FME Workspace, to be able to update the transformers with parameters based on my environment and run it first in FME desktop. I am using FME 2019 and Cityworks connector errors out saying its old version. And, there is also the JSON reader in the start that requires a dataset to set the "Address" Json schema, trying to Run the workspace and it throws an error. How did you setup Cityworks connector and JSON reader without pointing it to dataset?
is it possible to have a webex call with you, I am very close to get it to working. Whats is you emailID? Appreciate your help
Thanks Abdul
- 30 replies
- January 8, 2020
Hi @mannanhere,
Thanks for your question! Could you attach a screenshot of your Cityworks webhook? Also can you let me know what version of Cityworks you are using?
Generally I use the "Message as Subscriber Settings" topic URL from FME Server. It looks something like this:
https://<FME Server Host>/fmerest/v3/notifications/topics/<Topic Name>/message?fmetoken=<token>
You'll need to make sure that your FME Server is accessible from Cityworks (on the same network or publicly accessible via the web) and that your token is valid. I have had success using FME Cloud to set up Cityworks - FME workflows in the past.
Hope this helps,
Nathan
@nathanatsafe,
I'm following your article https://knowledge.safe.com/articles/100665/integrating-cityworks-and-fme.html to set up webhook action triggers between Cityworks and FME server.
But I have the same problem where the topic is not triggered in FME server,
resolved the network firewall issues between the two servers ,but I still get (401 unauthorized) or (400 bad request) errors when I use the "Message as Subscriber Settings " url in Action Manager.
Hoping to find some answers to resolve this issue.
Thank you
Adi
- Safer
- 281 replies
- January 8, 2020
@nathanatsafe,
I'm following your article https://knowledge.safe.com/articles/100665/integrating-cityworks-and-fme.html to set up webhook action triggers between Cityworks and FME server.
But I have the same problem where the topic is not triggered in FME server,
resolved the network firewall issues between the two servers ,but I still get (401 unauthorized) or (400 bad request) errors when I use the "Message as Subscriber Settings " url in Action Manager.
Hoping to find some answers to resolve this issue.
Thank you
Adi
Hi @adi,
From the response codes it sounds like the message is getting through to FME Server, but there may be a problem with the request or a permissions issue.
From the FME Server REST API documentation:
1400 Bad Request: The request was improperly formatted. Typically, this means that your JSON or XML is not well-formed. It may also mean that the URI is invalid; most path components can only contain alphanumeric characters.2401 Unauthorized: Authentication credentials are missing or incorrect.
Are you sure the token you're using with the topic URL has the appropriate permissions? Have you specified the Content-Type header in Cityworks Action Manager? Is your "Template" field (the data payload sent to FME Server) valid JSON?
Nathan
- 30 replies
- January 8, 2020
Hi @adi,
From the response codes it sounds like the message is getting through to FME Server, but there may be a problem with the request or a permissions issue.
From the FME Server REST API documentation:
1400 Bad Request: The request was improperly formatted. Typically, this means that your JSON or XML is not well-formed. It may also mean that the URI is invalid; most path components can only contain alphanumeric characters.2401 Unauthorized: Authentication credentials are missing or incorrect.
Are you sure the token you're using with the topic URL has the appropriate permissions? Have you specified the Content-Type header in Cityworks Action Manager? Is your "Template" field (the data payload sent to FME Server) valid JSON?
Nathan
Thank you @nathanatsafe
your sugesstions have really helped me ,I had invalid Json in my Template field.
appreciate it
- Safer
- 281 replies
- January 8, 2020
Thank you @nathanatsafe
your sugesstions have really helped me ,I had invalid Json in my Template field.
appreciate it
That's great! Happy integrating.
- 30 replies
- January 9, 2020
Hi @adi,
From the response codes it sounds like the message is getting through to FME Server, but there may be a problem with the request or a permissions issue.
From the FME Server REST API documentation:
1400 Bad Request: The request was improperly formatted. Typically, this means that your JSON or XML is not well-formed. It may also mean that the URI is invalid; most path components can only contain alphanumeric characters.2401 Unauthorized: Authentication credentials are missing or incorrect.
Are you sure the token you're using with the topic URL has the appropriate permissions? Have you specified the Content-Type header in Cityworks Action Manager? Is your "Template" field (the data payload sent to FME Server) valid JSON?
Nathan
Hello @nathanatsafe,
The fmetoken for the topic expires every day ,How would I change it to something that does not expire?
- Safer
- 281 replies
- January 9, 2020
Hello @nathanatsafe,
The fmetoken for the topic expires every day ,How would I change it to something that does not expire?
Hi @adi,
It might be best to create your own token and set the expiration. How you do this will vary slightly depending on your FME Server version. Please find a complete guide here: https://knowledge.safe.com/articles/101747/token-management-in-fme-server-2019.html.
Hope that helps!
Nathan
Hi, FME topics are not triggering from cityworks Action manager, FME throws a bad request error. I assume there is some special configuration required on Subscriptions / topics in order for Cityworks to work? Any help is appreciated. @nathanatsafe
Hi @mannanhere,
Thanks for your question! Could you attach a screenshot of your Cityworks webhook? Also can you let me know what version of Cityworks you are using?
Generally I use the "Message as Subscriber Settings" topic URL from FME Server. It looks something like this:
https://<FME Server Host>/fmerest/v3/notifications/topics/<Topic Name>/message?fmetoken=<token>
You'll need to make sure that your FME Server is accessible from Cityworks (on the same network or publicly accessible via the web) and that your token is valid. I have had success using FME Cloud to set up Cityworks - FME workflows in the past.
Hope this helps,
Nathan
Hi Nathan,
Thank you for your response, here are some screenshots and details. I am using Cityworks 15.3.3. Both Cityworks and FME server are on same Machine and accessible. I tried Postman to trigger the FME topic and it works but not through Action Manager
I am using the Topic URL as below: "http://XXX/fmerest/v3/notifications/topics/cityworks.trigger/message"
and then supplying credential user and password. I have tried the other way as well. with having fmetopic as query string.
@nathanatsafe
Hi Nathan,
Thank you for your response, here are some screenshots and details. I am using Cityworks 15.3.3. Both Cityworks and FME server are on same Machine and accessible. I tried Postman to trigger the FME topic and it works but not through Action Manager
I am using the Topic URL as below: "http://XXX/fmerest/v3/notifications/topics/cityworks.trigger/message"
and then supplying credential user and password. I have tried the other way as well. with having fmetopic as query string.
@nathanatsafe
Hi @mannanhere,
Thanks for the additional info. It does seem at-a-glance like your Cityworks webhook is set up correctly. If you check the message queue in Cityworks do you see the messages being set, failing, or pending? If pending, they might be getting stuck in the queue. Another thing worth checking would be the FME Server service log (for REST calls) and tomcat localhost_access logs. If you see anything in there from Cityworks then you know that there is data coming through at least.
Finally I remember vaguely that there may have been a bug in Cityworks with HTTP POSTs around your version so it might be worth checking in with your support contact at Cityworks.
Hope this helps,
Nathan
Hi Nathan,
Thank you for your response, here are some screenshots and details. I am using Cityworks 15.3.3. Both Cityworks and FME server are on same Machine and accessible. I tried Postman to trigger the FME topic and it works but not through Action Manager
I am using the Topic URL as below: "http://XXX/fmerest/v3/notifications/topics/cityworks.trigger/message"
and then supplying credential user and password. I have tried the other way as well. with having fmetopic as query string.
@nathanatsafe
Hi Nathan,
Thanks for the help, I was able to get the Action Manager working, I think the problem was supplying the FME token with the URL instead of Credentials in Action Manager and also probably due to how the data was being sent. The topic is being triggered now.
But I am facing another issue, after deploying Cityworks FME project, I took the FME Workspace, to be able to update the transformers with parameters based on my environment and run it first in FME desktop. I am using FME 2019 and Cityworks connector errors out saying its old version. And, there is also the JSON reader in the start that requires a dataset to set the "Address" Json schema, trying to Run the workspace and it throws an error. How did you setup Cityworks connector and JSON reader without pointing it to dataset?
is it possible to have a webex call with you, I am very close to get it to working. Whats is you emailID? Appreciate your help
Thanks Abdul
Hi @mannanhere,
Thanks for your question! Could you attach a screenshot of your Cityworks webhook? Also can you let me know what version of Cityworks you are using?
Generally I use the "Message as Subscriber Settings" topic URL from FME Server. It looks something like this:
https://<FME Server Host>/fmerest/v3/notifications/topics/<Topic Name>/message?fmetoken=<token>
You'll need to make sure that your FME Server is accessible from Cityworks (on the same network or publicly accessible via the web) and that your token is valid. I have had success using FME Cloud to set up Cityworks - FME workflows in the past.
Hope this helps,
Nathan
@nathanatsafe,
I'm following your article https://knowledge.safe.com/articles/100665/integrating-cityworks-and-fme.html to set up webhook action triggers between Cityworks and FME server.
But I have the same problem where the topic is not triggered in FME server,
resolved the network firewall issues between the two servers ,but I still get (401 unauthorized) or (400 bad request) errors when I use the "Message as Subscriber Settings " url in Action Manager.
Hoping to find some answers to resolve this issue.
Thank you
Adi
@nathanatsafe,
I'm following your article https://knowledge.safe.com/articles/100665/integrating-cityworks-and-fme.html to set up webhook action triggers between Cityworks and FME server.
But I have the same problem where the topic is not triggered in FME server,
resolved the network firewall issues between the two servers ,but I still get (401 unauthorized) or (400 bad request) errors when I use the "Message as Subscriber Settings " url in Action Manager.
Hoping to find some answers to resolve this issue.
Thank you
Adi
Hi @adi,
From the response codes it sounds like the message is getting through to FME Server, but there may be a problem with the request or a permissions issue.
From the FME Server REST API documentation:
1400 Bad Request: The request was improperly formatted. Typically, this means that your JSON or XML is not well-formed. It may also mean that the URI is invalid; most path components can only contain alphanumeric characters.401 Unauthorized: Authentication credentials are missing or incorrect.
Are you sure the token you're using with the topic URL has the appropriate permissions? Have you specified the Content-Type header in Cityworks Action Manager? Is your "Template" field (the data payload sent to FME Server) valid JSON?
Nathan
Hi @adi,
From the response codes it sounds like the message is getting through to FME Server, but there may be a problem with the request or a permissions issue.
From the FME Server REST API documentation:
1400 Bad Request: The request was improperly formatted. Typically, this means that your JSON or XML is not well-formed. It may also mean that the URI is invalid; most path components can only contain alphanumeric characters.401 Unauthorized: Authentication credentials are missing or incorrect.
Are you sure the token you're using with the topic URL has the appropriate permissions? Have you specified the Content-Type header in Cityworks Action Manager? Is your "Template" field (the data payload sent to FME Server) valid JSON?
Nathan
Thank you @nathanatsafe
your sugesstions have really helped me ,I had invalid Json in my Template field.
appreciate it
Thank you @nathanatsafe
your sugesstions have really helped me ,I had invalid Json in my Template field.
appreciate it
That's great! Happy integrating.
Hi @adi,
From the response codes it sounds like the message is getting through to FME Server, but there may be a problem with the request or a permissions issue.
From the FME Server REST API documentation:
1400 Bad Request: The request was improperly formatted. Typically, this means that your JSON or XML is not well-formed. It may also mean that the URI is invalid; most path components can only contain alphanumeric characters.401 Unauthorized: Authentication credentials are missing or incorrect.
Are you sure the token you're using with the topic URL has the appropriate permissions? Have you specified the Content-Type header in Cityworks Action Manager? Is your "Template" field (the data payload sent to FME Server) valid JSON?
Nathan
Hello @nathanatsafe,
The fmetoken for the topic expires every day ,How would I change it to something that does not expire?
Hello @nathanatsafe,
The fmetoken for the topic expires every day ,How would I change it to something that does not expire?
Hi @adi,
It might be best to create your own token and set the expiration. How you do this will vary slightly depending on your FME Server version. Please find a complete guide here: https://knowledge.safe.com/articles/101747/token-management-in-fme-server-2019.html.
Hope that helps!
Nathan
Related Topics
I am trying to monitor a topic (receiving email) but getting an error connecting to the monitoring service.icon
Flow Hostedurl encoding in the Automationsicon
AutomationHow to trigger an Automation when a server job fails without using the Topic protocol?icon
AutomationFME Server Automation | simplify trigger event testing
Protocol to trigger a workspaceicon
Authoring
Helpful Members This Week
- hkingsbury
21 votes
- virtualcitymatt
8 votes
- liamfez
8 votes
- alexbiz
7 votes
- ebygomm
7 votes
- redgeographics
6 votes
- chriswilson
6 votes
- david_r
5 votes
- crutledge
5 votes
- DanAtSafe
5 votes
Recently Solved Questions
Community Stats
- 31,927
- Posts
- 121,264
- Replies
- 39,553
- Members
Latest FME
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
Scanning file for viruses.
Sorry, we're still checking this file's contents to make sure it's safe to download. Please try again in a few minutes.
OKThis file cannot be downloaded
Sorry, our virus scanner detected that this file isn't safe to download.
OKCookie policy
We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.
Cookie settings
We use 3 different kinds of cookies. You can choose which cookies you want to accept. We need basic cookies to make this site work, therefore these are the minimum you can select. Learn more about our cookies.