Two DoFileRestCallActivity has been added.

TigerSoftware

Administrator
Staff member
I've been working with the Wordpress api and needed to upload images. So I figured I would add two new actions to our automation that does the same thing. Same requirements as a Rest Call but also takes the path to a file.

This will also set your header fields needed for the upload.

The difference between the two calls is one returns json. Wordpress API returns json, but there could be other API's that doesn't return anything.

Will be in the next update.

You can also upload files through the AddFileMultiPartActivity, but this is a lot easier if the API accepts it.


Thomas
 
Last edited:

schmutlyBOT

Super Moderator
Staff member
Just saw lol. Thats good. So this call will take care of Multipart uploads for large files (in part 1, part 2, etc) and also Multifile for lots of small images?
I guess it does as you have AddFileMultiPartActivity also. Oh...idiot đŸ˜… I didn't read the title..."TWO" excellent. lol
 

TigerSoftware

Administrator
Staff member
Just saw lol. Thats good. So this call will take care of Multipart uploads for large files (in part 1, part 2, etc) and also Multifile for lots of small images?
I guess it does as you have AddFileMultiPartActivity also. Oh...idiot đŸ˜… I didn't read the title..."TWO" excellent. lol

This call will set the body of the call to the file and add a file attachment header/content-type header.

One will expect json to return. Like the Wordpress API for media (images). You would use this to send a image or file to the Wordpress API and get back json for the mediaitem.

The other action won't expect json. Just a 200 OK response.

Other API's may require the multi-part form type of header. That is the hard part about doing the Rest API's. They may require different ways of sending images so it's hard to make it easy.

Thomas
 
Top