Jump to content
paulminors

[SOLVED] Alfred notification message

Recommended Posts

Hi everyone.

 

I have a workflow that I use to create tasks in Asana using Alfred. I have a notification that I'd like to show the task (Query) when it's done. It used to work, but now the notification shows as this:

 

886619096_AlredNotification.png.6cbdd246a900d9f39a75782d2afbc24f.png

 

Here's the setting:

 

1069665984_Screenshot2019-01-0910_46_26.png.f086654ba4db6089944f862abe0a13ea.png

 

Thanks in advance for any advice :)

Share this post


Link to post

Hi Paul,

 

I'm going to move this to the Workflow Help & Question forum. If you're not talking about your own workflow, then it probably really belongs in the actual workflow's thread, where people who know the workflow (not least its developer) can provide a proper answer.

 

The problem is that the workflow is sending a bunch of JSON to a Post Notification element. I can't possibly say more than that based on screenshots.

 

 

Share this post


Link to post
2 minutes ago, paulminors said:

Does this screenshot help?

 

Not in the slightest, I'm afraid. Please read and follow the "Reporting Problems with Workflows" I just linked.

 

As I said, you're seeing a bunch of JSON in the notification because your workflow is sending a bunch of JSON to the Post Notification element.

 

I can't possibly give you a more precise answer specific to the workflow you're talking about because I do not have the workflow you're talking about.

Share this post


Link to post
Posted (edited)

And what exactly do you want to see in the notification?

 

I think I just added a note or three called "deans-test" to your thing. I've tried messing with the URL/query, but it doesn't seem to make much difference to the API response.

 

From my reading of the API docs, however, a bad call should return a 4xx response.

 

I can't get it to, but you're not checking for failure in any case.

 

Changing your Run Script to the following should help (replace success with whatever you want to be shown in the notification body):

curl -sSL $ZAP_URL?note="{query}" >/dev/null
echo -n "success"

 

That sends whatever curl returns to /dev/null (i.e. a blackhole) and you'll only see what's echoed in the notification.

 

If that's okay for you, delete the above workflow from your Dropbox, so Internet randos can't spam your Zapier with stuff.

Edited by deanishe

Share this post


Link to post
Posted (edited)

To confirm, your tests came through to my account so they all worked fine.

 

Thanks, that seems to be working better. However, in the notification to show, I'd like the Alfred query to show. So the notification should be:

 

Task Created!

deans-test

Edited by paulminors

Share this post


Link to post

Thanks for that, it's working perfectly now.

 

Weird though - when I put in {query} before, it wasn't working. I must have done something wrong. 

 

Thanks again!

Share this post


Link to post

Ah sorry, just one more thing on this. I notice that with an Alfred Query that has spaces, the notification comes through encoded. Do you know how I would avoid this?

 

1543441816_Screenshot2019-01-1014_14_00.png.6be639a9760d068e23d1c932e2535ca7.png

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...