Re: DELETE url

2019-07-06 Thread J. Landman Gay via use-livecode
This has been a fascinating discussion and you guys have been very helpful. 
Gotta thank Charles for the ready-made handler and Stephen for the even 
shorter one.


I read Charles' first and told the Rails programmer that I could indeed 
send DELETE but it would take some scripting I'd never used before so we'd 
need to test. (Later I saw Stephen's.) She said "oh, never mind, it will 
take me 5 minutes to turn it into a POST." So once again I have managed to 
dodge the bullet and Dar should be happy as well.  :-)


Please do carry on, I might even learn something.

--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
On July 6, 2019 10:24:32 AM Dar Scott via use-livecode 
 wrote:



Oh, RFC2616 is so twentieth century.

However, RFC7231 HTTP/1.1 agrees with the responses: 200 (OK), 202 
(Accepted), or 204 (No Content).


It does have a couple examples that seems to indicate that DELETE might be 
used for logout, should one have imagination:


	DELETE might be used to remove a resource previously created with PUT (as 
I described).


	DELETE might be used to remove a resource previously created with a POST 
that returns a 201 (Created) status.


POST is favored for login, or so it seems from a quick search. POST is a 
command, an action. A wide range of status responses are allowed. So, 
perhaps the first login returns a 201 (Created) and subsequent logins 
either create new sessions (201) or return the same session (200). I think 
I saw a few cases where the responses were 200 and 404. Use of 200 with 
POST means that a proxy must have POST caching turned off or tweaked.


The 201 might return something like 
http://www.example.com/api/jj73koaiekdyu33/ 
. The session key is part of 
the URL. Subsequent queries would use this as the base URL. DELETE would 
delete that.


This makes DELETE look more acceptable as logout.

However, this falls apart when we look at authentication. A token is 
usually not returned in a 201 as part of a session URL, but is more often a 
value that is returned in the authentication header for subsequent use of 
the session. It can also be returned as a cookie and subsequent requests 
use the cookie. In these scenarios, the semantic coherence of DELETE starts 
to fall apart.


Also, login and logout are verbs. That seems to vote for POST for both.

Yet, give me the protocol and I will work with it. I am not really as 
cranky as I claim.


Dar Scott
darsc...@darzlab.com

On Jul 5, 2019, at 8:07 PM, Mark Wieder via use-livecode 
 wrote:


On 7/5/19 6:13 PM, Dar Scott Consulting via use-livecode wrote:

And an aside. Off topic.
I guess I am old-school. I know it is the fad, but using DELETE to logout 
seems goofy. Yeah, you can make a URL that looks like a session and you are 
deleting the session. But it seems that is like using HEAD to indicate what 
direction you are going or OPTIONS to set up options.
I know. I'm a cranky curmudgeon. I survive by recognizing that this is no 
longer HTTP, but a wolf in sheep's clothing to get past firewalls, a whole 
new protocol where we make it up as we go.
Now, given that, and I join the 21st century, DELETE returns a status code 
and an optional content. The status code is normally 204 (but maybe 205, 
which might be appropriate for log out) when no content is returned or 200 
if content is returned. If the item is not there, the same applies, but 
perhaps 404 or 410 can also apply. If DELETE is used to mean logout, then 
the session is permanently gone and 410 on a repeat is appropriate. A 303 
is OK (content is URL), but is probably handled by the underlying library.
Now, for proper symmetry, if DELETE is used to log out, then PUT must be 
used to log in. Both are idempotent, so logging in multiple times should be 
OK and logging out multiple times should be OK.  That is, a login returns 
200 and a logout returns 204.  Every time.

I have not seen it implemented that way. We play the hands we are dealt.


RFC 2616 describes only three possible responses to a DELETE verb:
200: the response includes an entity describing the status
202: the action has not yet been enacted
204: the action has been enacted but there is no status entity

Idempotence appears to be optional. RFC2616 states that certain verbs "can" 
have this property. That said, not all servers or web apps support the 
DELETE verb - there's usually an option to enable/disable it.


And I'm with you on the weirdness of using DELETE to log out. Bleah.

But to Jacque's point, see this:


--
Mark Wieder
ahsoftw...@gmail.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your 
subscription preferences:

http://lists.runrev.com/mailman/listinfo/use-livecode



Re: DELETE url

2019-07-06 Thread Dar Scott via use-livecode
Oh, RFC2616 is so twentieth century.

However, RFC7231 HTTP/1.1 agrees with the responses: 200 (OK), 202 (Accepted), 
or 204 (No Content).

It does have a couple examples that seems to indicate that DELETE might be used 
for logout, should one have imagination:

DELETE might be used to remove a resource previously created with PUT 
(as I described).

DELETE might be used to remove a resource previously created with a 
POST that returns a 201 (Created) status.

POST is favored for login, or so it seems from a quick search. POST is a 
command, an action. A wide range of status responses are allowed. So, perhaps 
the first login returns a 201 (Created) and subsequent logins either create new 
sessions (201) or return the same session (200). I think I saw a few cases 
where the responses were 200 and 404. Use of 200 with POST means that a proxy 
must have POST caching turned off or tweaked.

The 201 might return something like http://www.example.com/api/jj73koaiekdyu33/ 
. The session key is part of the 
URL. Subsequent queries would use this as the base URL. DELETE would delete 
that.

This makes DELETE look more acceptable as logout.

However, this falls apart when we look at authentication. A token is usually 
not returned in a 201 as part of a session URL, but is more often a value that 
is returned in the authentication header for subsequent use of the session. It 
can also be returned as a cookie and subsequent requests use the cookie. In 
these scenarios, the semantic coherence of DELETE starts to fall apart.  

Also, login and logout are verbs. That seems to vote for POST for both.  

Yet, give me the protocol and I will work with it. I am not really as cranky as 
I claim.

Dar Scott
darsc...@darzlab.com

> On Jul 5, 2019, at 8:07 PM, Mark Wieder via use-livecode 
>  wrote:
> 
> On 7/5/19 6:13 PM, Dar Scott Consulting via use-livecode wrote:
>> And an aside. Off topic.
>> I guess I am old-school. I know it is the fad, but using DELETE to logout 
>> seems goofy. Yeah, you can make a URL that looks like a session and you are 
>> deleting the session. But it seems that is like using HEAD to indicate what 
>> direction you are going or OPTIONS to set up options.
>> I know. I'm a cranky curmudgeon. I survive by recognizing that this is no 
>> longer HTTP, but a wolf in sheep's clothing to get past firewalls, a whole 
>> new protocol where we make it up as we go.
>> Now, given that, and I join the 21st century, DELETE returns a status code 
>> and an optional content. The status code is normally 204 (but maybe 205, 
>> which might be appropriate for log out) when no content is returned or 200 
>> if content is returned. If the item is not there, the same applies, but 
>> perhaps 404 or 410 can also apply. If DELETE is used to mean logout, then 
>> the session is permanently gone and 410 on a repeat is appropriate. A 303 is 
>> OK (content is URL), but is probably handled by the underlying library.
>> Now, for proper symmetry, if DELETE is used to log out, then PUT must be 
>> used to log in. Both are idempotent, so logging in multiple times should be 
>> OK and logging out multiple times should be OK.  That is, a login returns 
>> 200 and a logout returns 204.  Every time.
>> I have not seen it implemented that way. We play the hands we are dealt.
> 
> RFC 2616 describes only three possible responses to a DELETE verb:
> 200: the response includes an entity describing the status
> 202: the action has not yet been enacted
> 204: the action has been enacted but there is no status entity
> 
> Idempotence appears to be optional. RFC2616 states that certain verbs "can" 
> have this property. That said, not all servers or web apps support the DELETE 
> verb - there's usually an option to enable/disable it.
> 
> And I'm with you on the weirdness of using DELETE to log out. Bleah.
> 
> But to Jacque's point, see this:
> 
> 
> -- 
> Mark Wieder
> ahsoftw...@gmail.com
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: DELETE url

2019-07-05 Thread Mark Wieder via use-livecode

On 7/5/19 6:13 PM, Dar Scott Consulting via use-livecode wrote:

And an aside. Off topic.

I guess I am old-school. I know it is the fad, but using DELETE to logout seems 
goofy. Yeah, you can make a URL that looks like a session and you are deleting 
the session. But it seems that is like using HEAD to indicate what direction 
you are going or OPTIONS to set up options.

I know. I'm a cranky curmudgeon. I survive by recognizing that this is no 
longer HTTP, but a wolf in sheep's clothing to get past firewalls, a whole new 
protocol where we make it up as we go.

Now, given that, and I join the 21st century, DELETE returns a status code and 
an optional content. The status code is normally 204 (but maybe 205, which 
might be appropriate for log out) when no content is returned or 200 if content 
is returned. If the item is not there, the same applies, but perhaps 404 or 410 
can also apply. If DELETE is used to mean logout, then the session is 
permanently gone and 410 on a repeat is appropriate. A 303 is OK (content is 
URL), but is probably handled by the underlying library.

Now, for proper symmetry, if DELETE is used to log out, then PUT must be used 
to log in. Both are idempotent, so logging in multiple times should be OK and 
logging out multiple times should be OK.  That is, a login returns 200 and a 
logout returns 204.  Every time.

I have not seen it implemented that way. We play the hands we are dealt.


RFC 2616 describes only three possible responses to a DELETE verb:
200: the response includes an entity describing the status
202: the action has not yet been enacted
204: the action has been enacted but there is no status entity

Idempotence appears to be optional. RFC2616 states that certain verbs 
"can" have this property. That said, not all servers or web apps support 
the DELETE verb - there's usually an option to enable/disable it.


And I'm with you on the weirdness of using DELETE to log out. Bleah.

But to Jacque's point, see this:


--
 Mark Wieder
 ahsoftw...@gmail.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: DELETE url

2019-07-05 Thread Stephen MacLean via use-livecode
This works for me:

delete URL(tPostURL)


tPostURL is the URL you want to send the delete to. The URL can include an API 
call, authentication token, etc.

I do have LC Business, but don’t need to use tsNet for this specifically, 
although I do use it for some other things.

You can find all the commands, etc. for tsNet here:

https://www.techstrategies.com.au/tsnet-resources/ 
<https://www.techstrategies.com.au/tsnet-resources/>

as well as some sample stacks that I have found invaluable for seeing how it 
all works.

Best,
Steve MacLean


> On Jul 5, 2019, at 6:27 PM, Stephen MacLean via use-livecode 
>  wrote:
> 
> Hi J,
> 
> DELETE does work, it’s used in the WP library. 
> 
> I’m out right now, but will find the code and send you a sample when I get 
> back. 
> 
> Best,
> Steve MacLean
> 
>> On Jul 5, 2019, at 6:23 PM, J. Landman Gay via use-livecode 
>>  wrote:
>> 
>> The server lady wants it that way. I create signed AWS URLs that are secure 
>> and which access her APIs. So far we've only used POST, PUT, and GET. Now 
>> we've added a "log out" function and I'm supposed to send the URL with 
>> DELETE. She is floored that I can't do that:
>> 
>> "I can change it if you really don’t have DELETE, but I would find it 
>> surprising. If you do have it, I’d prefer to keep it as DELETE since it 
>> makes the most sense for the action."
>> 
>> Then she suggests using cURL but that won't work on mobile where we can't 
>> use shell.
>> 
>> I wouldn't know where to start with tsNetCustom(), but I'll investigate. 
>> Suggestions welcome, provided it works on mobile.
>> 
>>> On 7/5/19 3:30 PM, Dar Scott Consulting via use-livecode wrote:
>>> Testing DELETE is scary. Consider httpstat.us <http://httpstat.us/>, 
>>> httpbin.org <http://httpbin.org/> or others for safe testing.
>>> I haven't tested, but I'd think that 'delete URL 
>>> "http://www.example.com/oldthings.txt 
>>> <http://www.example.com/oldthings.txt>"' should work.
>>> You might need to pass along some auth:
>>> delete URL "http://badwolf:swordf...@www.example.com/secretthings.txt 
>>> <http://badwolf:swordf...@www.example.com/secretthings.txt>"
>>> If not, you can directly use TCP. It is as easy as a simple GET. It is as 
>>> hard as figuring out simple HTTP.
>>> Or consider tsNetCustom() and use "DELETE" as the request.
>>> Dar Scott
>>> darzLab
>>>> On Jul 5, 2019, at 1:55 PM, J. Landman Gay via use-livecode 
>>>>  wrote:
>>>> 
>>>> I need to send a DELETE to a server. I only know of PUT, GET, and POST 
>>>> options. Does tsNet support DELETE? If not, how would I do that?
>>>> 
>>>> -- 
>>>> Jacqueline Landman Gay | jac...@hyperactivesw.com
>>>> HyperActive Software   | http://www.hyperactivesw.com
>> 
>> 
>> -- 
>> Jacqueline Landman Gay | jac...@hyperactivesw.com
>> HyperActive Software   | http://www.hyperactivesw.com
>> 
>> 
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your subscription 
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> 
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: DELETE url

2019-07-05 Thread Dar Scott Consulting via use-livecode
And an aside. Off topic.

I guess I am old-school. I know it is the fad, but using DELETE to logout seems 
goofy. Yeah, you can make a URL that looks like a session and you are deleting 
the session. But it seems that is like using HEAD to indicate what direction 
you are going or OPTIONS to set up options.  

I know. I'm a cranky curmudgeon. I survive by recognizing that this is no 
longer HTTP, but a wolf in sheep's clothing to get past firewalls, a whole new 
protocol where we make it up as we go.

Now, given that, and I join the 21st century, DELETE returns a status code and 
an optional content. The status code is normally 204 (but maybe 205, which 
might be appropriate for log out) when no content is returned or 200 if content 
is returned. If the item is not there, the same applies, but perhaps 404 or 410 
can also apply. If DELETE is used to mean logout, then the session is 
permanently gone and 410 on a repeat is appropriate. A 303 is OK (content is 
URL), but is probably handled by the underlying library.  

Now, for proper symmetry, if DELETE is used to log out, then PUT must be used 
to log in. Both are idempotent, so logging in multiple times should be OK and 
logging out multiple times should be OK.  That is, a login returns 200 and a 
logout returns 204.  Every time.

I have not seen it implemented that way. We play the hands we are dealt. 

Dar Scott


> On Jul 5, 2019, at 4:23 PM, J. Landman Gay via use-livecode 
>  wrote:
> 
> The server lady wants it that way. I create signed AWS URLs that are secure 
> and which access her APIs. So far we've only used POST, PUT, and GET. Now 
> we've added a "log out" function and I'm supposed to send the URL with 
> DELETE. She is floored that I can't do that:
> 
> "I can change it if you really don’t have DELETE, but I would find it 
> surprising. If you do have it, I’d prefer to keep it as DELETE since it makes 
> the most sense for the action."
> 
> Then she suggests using cURL but that won't work on mobile where we can't use 
> shell.
> 
> I wouldn't know where to start with tsNetCustom(), but I'll investigate. 
> Suggestions welcome, provided it works on mobile.
> 
> On 7/5/19 3:30 PM, Dar Scott Consulting via use-livecode wrote:
>> Testing DELETE is scary. Consider httpstat.us <http://httpstat.us/>, 
>> httpbin.org <http://httpbin.org/> or others for safe testing.
>> I haven't tested, but I'd think that 'delete URL 
>> "http://www.example.com/oldthings.txt 
>> <http://www.example.com/oldthings.txt>"' should work.
>> You might need to pass along some auth:
>> delete URL "http://badwolf:swordf...@www.example.com/secretthings.txt 
>> <http://badwolf:swordf...@www.example.com/secretthings.txt>"
>> If not, you can directly use TCP. It is as easy as a simple GET. It is as 
>> hard as figuring out simple HTTP.
>> Or consider tsNetCustom() and use "DELETE" as the request.
>> Dar Scott
>> darzLab
>>> On Jul 5, 2019, at 1:55 PM, J. Landman Gay via use-livecode 
>>>  wrote:
>>> 
>>> I need to send a DELETE to a server. I only know of PUT, GET, and POST 
>>> options. Does tsNet support DELETE? If not, how would I do that?
>>> 
>>> -- 
>>> Jacqueline Landman Gay | jac...@hyperactivesw.com
>>> HyperActive Software   | http://www.hyperactivesw.com
> 
> 
> -- 
> Jacqueline Landman Gay | jac...@hyperactivesw.com
> HyperActive Software   | http://www.hyperactivesw.com
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
> 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: DELETE url

2019-07-05 Thread Dar Scott Consulting via use-livecode
You know where to start with tsNetCustom(); look in the dictionary. From there? 
Maybe compare that with tsNetGet() and make changes as needed.  

> On Jul 5, 2019, at 4:23 PM, J. Landman Gay via use-livecode 
>  wrote:
> 
> The server lady wants it that way. I create signed AWS URLs that are secure 
> and which access her APIs. So far we've only used POST, PUT, and GET. Now 
> we've added a "log out" function and I'm supposed to send the URL with 
> DELETE. She is floored that I can't do that:
> 
> "I can change it if you really don’t have DELETE, but I would find it 
> surprising. If you do have it, I’d prefer to keep it as DELETE since it makes 
> the most sense for the action."
> 
> Then she suggests using cURL but that won't work on mobile where we can't use 
> shell.
> 
> I wouldn't know where to start with tsNetCustom(), but I'll investigate. 
> Suggestions welcome, provided it works on mobile.
> 
> On 7/5/19 3:30 PM, Dar Scott Consulting via use-livecode wrote:
>> Testing DELETE is scary. Consider httpstat.us <http://httpstat.us/>, 
>> httpbin.org <http://httpbin.org/> or others for safe testing.
>> I haven't tested, but I'd think that 'delete URL 
>> "http://www.example.com/oldthings.txt 
>> <http://www.example.com/oldthings.txt>"' should work.
>> You might need to pass along some auth:
>> delete URL "http://badwolf:swordf...@www.example.com/secretthings.txt 
>> <http://badwolf:swordf...@www.example.com/secretthings.txt>"
>> If not, you can directly use TCP. It is as easy as a simple GET. It is as 
>> hard as figuring out simple HTTP.
>> Or consider tsNetCustom() and use "DELETE" as the request.
>> Dar Scott
>> darzLab
>>> On Jul 5, 2019, at 1:55 PM, J. Landman Gay via use-livecode 
>>>  wrote:
>>> 
>>> I need to send a DELETE to a server. I only know of PUT, GET, and POST 
>>> options. Does tsNet support DELETE? If not, how would I do that?
>>> 
>>> -- 
>>> Jacqueline Landman Gay | jac...@hyperactivesw.com
>>> HyperActive Software   | http://www.hyperactivesw.com
> 
> 
> -- 
> Jacqueline Landman Gay | jac...@hyperactivesw.com
> HyperActive Software   | http://www.hyperactivesw.com
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
> 


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: DELETE url

2019-07-05 Thread Charles Warwick via use-livecode
Hi,

You can send a HTTP DELETE using tsNet.  There is a lesson here that shows you 
how:

http://lessons.livecode.com/m/4071/l/856543-how-to-send-a-custom-http-request-using-the-tsnet-external

All tsNet functions work on mobile, so no issue there either.

Regards,

Charles

> On 6 Jul 2019, at 8:27 am, Stephen MacLean via use-livecode 
>  wrote:
> 
> Hi J,
> 
> DELETE does work, it’s used in the WP library. 
> 
> I’m out right now, but will find the code and send you a sample when I get 
> back. 
> 
> Best,
> Steve MacLean
> 
>> On Jul 5, 2019, at 6:23 PM, J. Landman Gay via use-livecode 
>>  wrote:
>> 
>> The server lady wants it that way. I create signed AWS URLs that are secure 
>> and which access her APIs. So far we've only used POST, PUT, and GET. Now 
>> we've added a "log out" function and I'm supposed to send the URL with 
>> DELETE. She is floored that I can't do that:
>> 
>> "I can change it if you really don’t have DELETE, but I would find it 
>> surprising. If you do have it, I’d prefer to keep it as DELETE since it 
>> makes the most sense for the action."
>> 
>> Then she suggests using cURL but that won't work on mobile where we can't 
>> use shell.
>> 
>> I wouldn't know where to start with tsNetCustom(), but I'll investigate. 
>> Suggestions welcome, provided it works on mobile.
>> 
>>> On 7/5/19 3:30 PM, Dar Scott Consulting via use-livecode wrote:
>>> Testing DELETE is scary. Consider httpstat.us <http://httpstat.us/>, 
>>> httpbin.org <http://httpbin.org/> or others for safe testing.
>>> I haven't tested, but I'd think that 'delete URL 
>>> "http://www.example.com/oldthings.txt 
>>> <http://www.example.com/oldthings.txt>"' should work.
>>> You might need to pass along some auth:
>>> delete URL "http://badwolf:swordf...@www.example.com/secretthings.txt 
>>> <http://badwolf:swordf...@www.example.com/secretthings.txt>"
>>> If not, you can directly use TCP. It is as easy as a simple GET. It is as 
>>> hard as figuring out simple HTTP.
>>> Or consider tsNetCustom() and use "DELETE" as the request.
>>> Dar Scott
>>> darzLab
>>>> On Jul 5, 2019, at 1:55 PM, J. Landman Gay via use-livecode 
>>>>  wrote:
>>>> 
>>>> I need to send a DELETE to a server. I only know of PUT, GET, and POST 
>>>> options. Does tsNet support DELETE? If not, how would I do that?
>>>> 
>>>> -- 
>>>> Jacqueline Landman Gay | jac...@hyperactivesw.com
>>>> HyperActive Software   | http://www.hyperactivesw.com
>> 
>> 
>> -- 
>> Jacqueline Landman Gay | jac...@hyperactivesw.com
>> HyperActive Software   | http://www.hyperactivesw.com
>> 
>> 
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your subscription 
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
> 
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: DELETE url

2019-07-05 Thread Stephen MacLean via use-livecode
Hi J,

DELETE does work, it’s used in the WP library. 

I’m out right now, but will find the code and send you a sample when I get 
back. 

Best,
Steve MacLean

> On Jul 5, 2019, at 6:23 PM, J. Landman Gay via use-livecode 
>  wrote:
> 
> The server lady wants it that way. I create signed AWS URLs that are secure 
> and which access her APIs. So far we've only used POST, PUT, and GET. Now 
> we've added a "log out" function and I'm supposed to send the URL with 
> DELETE. She is floored that I can't do that:
> 
> "I can change it if you really don’t have DELETE, but I would find it 
> surprising. If you do have it, I’d prefer to keep it as DELETE since it makes 
> the most sense for the action."
> 
> Then she suggests using cURL but that won't work on mobile where we can't use 
> shell.
> 
> I wouldn't know where to start with tsNetCustom(), but I'll investigate. 
> Suggestions welcome, provided it works on mobile.
> 
>> On 7/5/19 3:30 PM, Dar Scott Consulting via use-livecode wrote:
>> Testing DELETE is scary. Consider httpstat.us <http://httpstat.us/>, 
>> httpbin.org <http://httpbin.org/> or others for safe testing.
>> I haven't tested, but I'd think that 'delete URL 
>> "http://www.example.com/oldthings.txt 
>> <http://www.example.com/oldthings.txt>"' should work.
>> You might need to pass along some auth:
>> delete URL "http://badwolf:swordf...@www.example.com/secretthings.txt 
>> <http://badwolf:swordf...@www.example.com/secretthings.txt>"
>> If not, you can directly use TCP. It is as easy as a simple GET. It is as 
>> hard as figuring out simple HTTP.
>> Or consider tsNetCustom() and use "DELETE" as the request.
>> Dar Scott
>> darzLab
>>> On Jul 5, 2019, at 1:55 PM, J. Landman Gay via use-livecode 
>>>  wrote:
>>> 
>>> I need to send a DELETE to a server. I only know of PUT, GET, and POST 
>>> options. Does tsNet support DELETE? If not, how would I do that?
>>> 
>>> -- 
>>> Jacqueline Landman Gay | jac...@hyperactivesw.com
>>> HyperActive Software   | http://www.hyperactivesw.com
> 
> 
> -- 
> Jacqueline Landman Gay | jac...@hyperactivesw.com
> HyperActive Software   | http://www.hyperactivesw.com
> 
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode



___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: DELETE url

2019-07-05 Thread J. Landman Gay via use-livecode
The server lady wants it that way. I create signed AWS URLs that are 
secure and which access her APIs. So far we've only used POST, PUT, and 
GET. Now we've added a "log out" function and I'm supposed to send the 
URL with DELETE. She is floored that I can't do that:


"I can change it if you really don’t have DELETE, but I would find it 
surprising. If you do have it, I’d prefer to keep it as DELETE since it 
makes the most sense for the action."


Then she suggests using cURL but that won't work on mobile where we 
can't use shell.


I wouldn't know where to start with tsNetCustom(), but I'll investigate. 
Suggestions welcome, provided it works on mobile.


On 7/5/19 3:30 PM, Dar Scott Consulting via use-livecode wrote:

Testing DELETE is scary. Consider httpstat.us <http://httpstat.us/>, httpbin.org 
<http://httpbin.org/> or others for safe testing.

I haven't tested, but I'd think that 'delete URL "http://www.example.com/oldthings.txt 
<http://www.example.com/oldthings.txt>"' should work.

You might need to pass along some auth:
delete URL "http://badwolf:swordf...@www.example.com/secretthings.txt 
<http://badwolf:swordf...@www.example.com/secretthings.txt>"

If not, you can directly use TCP. It is as easy as a simple GET. It is as hard 
as figuring out simple HTTP.

Or consider tsNetCustom() and use "DELETE" as the request.


Dar Scott
darzLab


On Jul 5, 2019, at 1:55 PM, J. Landman Gay via use-livecode 
 wrote:

I need to send a DELETE to a server. I only know of PUT, GET, and POST options. 
Does tsNet support DELETE? If not, how would I do that?

--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com



--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Re: DELETE url

2019-07-05 Thread Dar Scott Consulting via use-livecode
Testing DELETE is scary. Consider httpstat.us <http://httpstat.us/>, 
httpbin.org <http://httpbin.org/> or others for safe testing.

I haven't tested, but I'd think that 'delete URL 
"http://www.example.com/oldthings.txt <http://www.example.com/oldthings.txt>"' 
should work. 

You might need to pass along some auth:
delete URL "http://badwolf:swordf...@www.example.com/secretthings.txt 
<http://badwolf:swordf...@www.example.com/secretthings.txt>"

If not, you can directly use TCP. It is as easy as a simple GET. It is as hard 
as figuring out simple HTTP.

Or consider tsNetCustom() and use "DELETE" as the request.


Dar Scott
darzLab

> On Jul 5, 2019, at 1:55 PM, J. Landman Gay via use-livecode 
>  wrote:
> 
> I need to send a DELETE to a server. I only know of PUT, GET, and POST 
> options. Does tsNet support DELETE? If not, how would I do that?
> 
> -- 
> Jacqueline Landman Gay | jac...@hyperactivesw.com
> HyperActive Software   | http://www.hyperactivesw.com
> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


DELETE url

2019-07-05 Thread J. Landman Gay via use-livecode
I need to send a DELETE to a server. I only know of PUT, GET, and POST 
options. Does tsNet support DELETE? If not, how would I do that?


--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: delete Url on mobile

2013-07-30 Thread Thomas McGrath III
How can one know something one day and then not know it the next. It is a 
conundrum.

Thanks G  J

T

-- Tom McGrath III
http://lazyriver.on-rev.com
mcgra...@mac.com

On Jul 30, 2013, at 12:16 AM, J. Landman Gay jac...@hyperactivesw.com wrote:

 On 7/29/13 9:19 PM, Thomas McGrath III wrote:
 Can you delete a file on mobile if it is in the engine folder?
delete URL (file:  specialFolderPath(engine)  /  tName)
 
 I doubt it. I believe the commandment is: thou shalt not write, nor edit, nor 
 delete, nor add to the sacred documents, lest thy sandbox become defiled with 
 corruption and render thy checksum invalid.
 
 -- 
 Jacqueline Landman Gay | jac...@hyperactivesw.com
 HyperActive Software   | http://www.hyperactivesw.com
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


delete Url on mobile

2013-07-29 Thread Thomas McGrath III
Can you delete a file on mobile if it is in the engine folder?
   delete URL (file:  specialFolderPath(engine)  /  tName)

Tom
-- Tom McGrath III
http://lazyriver.on-rev.com
mcgra...@mac.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: delete Url on mobile

2013-07-29 Thread Thomas McGrath III
Neither one of these works in the simulator?

delete URL (file:  specialFolderPath(engine)  /  tName)

delete file (specialFolderPath(engine)  /  tName)

-- Tom McGrath III
http://lazyriver.on-rev.com
mcgra...@mac.com

On Jul 29, 2013, at 10:19 PM, Thomas McGrath III mcgra...@mac.com wrote:

 Can you delete a file on mobile if it is in the engine folder?
   delete URL (file:  specialFolderPath(engine)  /  tName)
 
 Tom
 -- Tom McGrath III
 http://lazyriver.on-rev.com
 mcgra...@mac.com
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: delete Url on mobile

2013-07-29 Thread Gerry Orkin
On iOS at least you can't change the binary at run time in any way. Apple won't 
allow it.

g

On 30/07/2013, at 12:19 PM, Thomas McGrath III mcgra...@mac.com wrote:

 Can you delete a file on mobile if it is in the engine folder?
   delete URL (file:  specialFolderPath(engine)  /  tName)
 
 Tom
 -- Tom McGrath III
 http://lazyriver.on-rev.com
 mcgra...@mac.com
 
 ___
 use-livecode mailing list
 use-livecode@lists.runrev.com
 Please visit this url to subscribe, unsubscribe and manage your subscription 
 preferences:
 http://lists.runrev.com/mailman/listinfo/use-livecode


___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: delete Url on mobile

2013-07-29 Thread J. Landman Gay

On 7/29/13 9:19 PM, Thomas McGrath III wrote:

Can you delete a file on mobile if it is in the engine folder?
delete URL (file:  specialFolderPath(engine)  /  tName)


I doubt it. I believe the commandment is: thou shalt not write, nor 
edit, nor delete, nor add to the sacred documents, lest thy sandbox 
become defiled with corruption and render thy checksum invalid.


--
Jacqueline Landman Gay | jac...@hyperactivesw.com
HyperActive Software   | http://www.hyperactivesw.com

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode