-
-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WordPress compatibility #21
Comments
Hey @pfefferle, nice to hear you. HTTP ClientI don't have a lot of experiences on Wordpress but as far as I know, Wordpress has its own HTTP "stack" such as functions like Do you know if there are some higher level methods that implements PSR 7 / ? The idea behind this is to implement a driver parameter, as it has been made for caching or logging, so that you may configure it on the fly. fromJsonI just released a version 0.5.5 with a fromJson() method. Server partThe server part of this library does not listen on any port. It's more intended to be integrated in a controller method. It's a precision because I don't know if this is the blocking aspect in your usage. |
Hey @landrok, sorry for the late reply.
Nice, thanks! HTTP ClientAs you said, WordPress has it's own Nevertheless, do you see a way to remove the hard dependencies of the AlternativeIf this is not possible (at least in short term), do you think it make sense to "only" use the Activity Objects and keep the server handling we currently use? |
Hey @landrok how likely is it, that the PSR 7 driver feature will make it into the code?
Are you willing to accept pull requests? |
Hey Matthias, |
I have two more questions if you don't mind:
|
Guzzle and HTTP foundationGuzzle is used as an HTTP client and should be replaced by PSR-18 (ie: https://github.com/landrok/activitypub/blob/master/src/ActivityPhp/Server/Http/Request.php#L42) HTTP foundation is used as HTTP message and should be replaced by PSR-7 (ie: https://github.com/landrok/activitypub/blob/master/src/ActivityPhp/Server/Http/HttpSignature.php#L66) Maybe the 2 should be handled as 2 distinct commits, don't you think ? Signature verificationIt could be great. It goes beyond the scope of this "Wordpress compatibility" issue and needs another one that let us discuss about alternatives before implementing. |
By the way @Art4 has an open PR to Add PSR-7 support, with an accompanying PSR18-Adapter if anyone is able to test it with this library! |
Thanks for mentioning me 👍 Atm the adapter is only supporting Requests v2, but I'm working at support for Requests v1 too. I would be glad if my library could be helpful. Update: I released 1.0.0 with support for Requests v1 and v2. |
Hey @landrok , I am the author of the WordPress ActivityPub Plugin (https://github.com/pfefferle/wordpress-activitypub) and @mediaformat and I investigated if it is possible to use your lib in the plugin, so I have some questions.
fromJson
method for the Activity Objects, so that we will be able to init the objects, using the JSON request?The text was updated successfully, but these errors were encountered: