belle
belle

@cygnoir Btw, I've just had an idea for a workaround so you can update words_written in Exist via the Workflow/Shortcuts app & I think it's going to work. I'll let you know when I've got the whole thing ready for you.

|
Embed
Progress spinner
belle
belle

@cygnoir Done! Check out the Exist user forum for a couple of workflow links and explanation 😊

|
Embed
Progress spinner
cygnoir
cygnoir

@belle Eee! So excited to play with this! Thank you so much!

|
Embed
Progress spinner
belle
belle

@cygnoir No problem! Glad I found a way to get it to work. Let me know if you get stuck or confused at all!

|
Embed
Progress spinner
cygnoir
cygnoir

@belle I am stuck on figuring out how to modify the update workflow to send values for other days other than today.

|
Embed
Progress spinner
belle
belle

@cygnoir Are you trying to set the date to something different, like yesterday, or make the workflow ask you to choose a date when you run it?

|
Embed
Progress spinner
cygnoir
cygnoir

@belle I would like the workflow to ask me for the date (defaulting to today); I've done it with other workflows but I'm unfamiliar enough with this one not to know where to put the prompt.

|
Embed
Progress spinner
belle
belle

@cygnoir Sure. So you just need to change the value that says Current date in this screenshot. Can you make that value ask for input?

|
Embed
Progress spinner
rosemaryorchard
rosemaryorchard

@belle @cygnoir I would recommend adding a date action and setting it to Specified date and then "ask when run" - and getting that as a magic variable. The date would be like this: www.icloud.com/shortcuts...

|
Embed
Progress spinner
cygnoir
cygnoir

@belle I tried that but it didn’t ask me for the date.

|
Embed
Progress spinner
belle
belle

@cygnoir Did it ask you for anything? I think if you delete the value "Current Date" and replace it with "ask for input", you should be able to choose "Date" as the input type. Does that part work?

|
Embed
Progress spinner
cygnoir
cygnoir

@belle I did do that, but it didn't ask me for any input when I ran the shortcut.

|
Embed
Progress spinner
cygnoir
cygnoir

@belle Rather, it asked me for the attribute, which I chose, and the amount, which I input, and then didn't ask me for the date.

|
Embed
Progress spinner
belle
belle

@cygnoir Ah, okay. Let me have a think on that.

|
Embed
Progress spinner
belle
belle

@cygnoir Can you try adding a step near the beginning that asks for the date and uses "Set variable" to save it? Then put that variable for the date into the spot where "Current date" was in the original?

|
Embed
Progress spinner
cygnoir
cygnoir

@belle I was able to do that! But how do I check to see if the shortcut worked?

|
Embed
Progress spinner
belle
belle

@cygnoir Sorry, I didn't add alert messages or anything for that. At the bottom of the Shortcut there should be a little text box showing output from the API, do you see that? It should say both success and failure, & if it worked, there'll be details after success but not after failure

|
Embed
Progress spinner
belle
belle

@cygnoir You could also use Kirsty's example in that Exist user forum thread to add success and failure messages to it if you like.

|
Embed
Progress spinner
cygnoir
cygnoir

@belle Oops, I ran the shortcut without opening it up, so I didn't see the text box. I will try again. I meant to ask how I view words_written in Exist.io itself.

|
Embed
Progress spinner
cygnoir
cygnoir

@belle OK, now that I am running the shortcut correctly, I see in the text output for the Acquire shortcut: {"detail”:"Must supply a list of objects.”}

|
Embed
Progress spinner
belle
belle

@cygnoir Ah sorry, my fault. It'll only work with multiple attributes. I'll update it to do just one.

|
Embed
Progress spinner
belle
belle

@cygnoir Try this one: www.icloud.com/shortcuts...

|
Embed
Progress spinner
cygnoir
cygnoir

@belle Getting closer! Now it’s saying bad date. {"failed":[{"error_code":"bad_date","value":750,"name":"words_written","error":"Invalid date","date":"Sep 21, 2018 at 12:00"}],"success":[]}

|
Embed
Progress spinner
belle
belle

@cygnoir Ah, if you change the date, you need to keep the formatting the same. You want to choose ISO 8601 for the date and none for the time.

|
Embed
Progress spinner
cygnoir
cygnoir

@belle Ah, I had to add an additional Format Date step that wasn’t obvious before. Does this output mean it worked? {"failed":[],"success":[{"date":"2018-09-21","name":"words_written","value":750}]}

|
Embed
Progress spinner
belle
belle

@cygnoir It does!

|
Embed
Progress spinner
cygnoir
cygnoir

@belle Yay, I see the word totals showing up on Exist.io! I’m so excited! Thank you!

|
Embed
Progress spinner
belle
belle

@cygnoir Hooray!

|
Embed
Progress spinner
cygnoir
cygnoir

@belle Now I am going to be really bummed if my words_written totals don't correspond with higher mood. 😉

|
Embed
Progress spinner
belle
belle

@cygnoir Haha let's hope they do! Did you end up setting up a workflow that just does words written, or do you choose from the list each time?

|
Embed
Progress spinner
Bruce
Bruce

@cygnoir @belle I'm loving this conversation even though I understand maybe 10% of it. You two rawk! 🎸

|
Embed
Progress spinner
cygnoir
cygnoir

@belle I choose from the list each time. I would set it up to only update the words_written attribute, but I'm too nervous to change what's working.

|
Embed
Progress spinner
belle
belle

@cygnoir Oh sure. I always duplicate shortcuts before editing stuff for the same reason! It's pretty simple to get it to work for just one, and you can even leave the unused stuff there. Where the dictionary is that has name, date, and value, just make the value for the name key words_written instead of having a variable in a bubble there.

|
Embed
Progress spinner
belle
belle

@cygnoir I'm hoping to write up a post for the Exist blog about how these shortcuts work soon, so they're easier to understand and fiddle with.

|
Embed
Progress spinner
belle
belle

@Bruce 😏👍

|
Embed
Progress spinner