Skip to content
This repository has been archived by the owner. It is now read-only.

Add user endpoints #20

Closed
rmccue opened this Issue Nov 7, 2013 · 12 comments

Comments

Projects
None yet
5 participants
@rmccue
Copy link
Member

rmccue commented Nov 7, 2013

@ghost ghost assigned rmccue Nov 7, 2013

@rmarji

This comment has been minimized.

Copy link

rmarji commented Nov 15, 2013

how can I get this?

@royboy789

This comment has been minimized.

Copy link

royboy789 commented Nov 15, 2013

For now you can check out my repo - https://github.com/royboy789/WP-API it
has the code base for users in it.

On Fri, Nov 15, 2013 at 11:29 AM, rmarji notifications@github.com wrote:

how can I get this?


Reply to this email directly or view it on GitHubhttps://github.com//issues/20#issuecomment-28596587
.

Thank You,
Roy Sivan
www.roysivan.com
GuavaWorks
www.guavaworks.com
818.925.4214
415.889.9346

@robertoles

This comment has been minimized.

Copy link

robertoles commented Mar 18, 2014

Is there any update on when this will make it in to the master repository?
Can I help out in anyway?
Thanks!

@tobych

This comment has been minimized.

Copy link
Contributor

tobych commented Mar 28, 2014

I could really do with this for a current project. @rmccue, what are your thoughts on @royboy789's work so far? @royboy789, I suggest you at least commit your work to a branch, and keep your master up-to-date with the upstream, rebasing as you go. That way Ryan can merge your code way more easily.

@tobych

This comment has been minimized.

Copy link
Contributor

tobych commented Mar 28, 2014

Actually, IIRC the API changed since Roy's work, so it needs re-doing.

@tobych

This comment has been minimized.

Copy link
Contributor

tobych commented Mar 29, 2014

I've made a start on the users endpoint at tobych@72f4942

It's based on @royboy789 's work, but redone against the current code. It's on a branch, which is rebased against master. No unit tests, no POSTing, and I'm ignoring $fields. It works for me. Next I'll try to get POST working. Then try to get out the extended/custom user attributes that plugins such as s2members add (which is what I need this for). This is pretty naive code, because I'm utterly naive about WP. I doubt we should be including the user's password, for one thing. I hope this isn't a waste of your time, having a look at this!

@tobych

This comment has been minimized.

Copy link
Contributor

tobych commented Mar 29, 2014

I've got editing (PUT/PATCH) working on some fields: https://github.com/tobych/WP-API/compare/users
Also I've realized there's already an entity defined for User in the documentation. It has very few fields though.

@tobych

This comment has been minimized.

Copy link
Contributor

tobych commented Mar 29, 2014

I have DELETE working. I've realized that in WP, users have standard fields and "meta" fields, including some default fields. I guess they need to be handled cleverly. I want to get these out, next. Perhaps into a separate JSON dictionary within the main one.

@tobych

This comment has been minimized.

Copy link
Contributor

tobych commented Mar 30, 2014

I have PUT/PATCH and GET working nicely with metadata now. I'm representing data from serialized fields using a dictionary with a "unserialized" (and, for now, "serialized") key, so things work round-trip without the server needing to guess whether to serialize things. I've also moved the metadata to user_meta, away from the meta stuff already included in the User entity's definition (and implementation for Posts). One question is whether to bother representing every user_meta value as an array, or just do that when there really are multiple values. For now I'm always using an array, as anything else complicates things in the code.

@rmccue

This comment has been minimized.

Copy link
Member Author

rmccue commented Apr 6, 2014

@tobych As noted in #68, can you please open a pull request for your branch without the meta handling? We can handle that separately. I like the way you've implemented it so far, so a pull request would help me review it and get it merged. :)

@tobych

This comment has been minimized.

Copy link
Contributor

tobych commented Apr 8, 2014

I've just opened a pull request for this work without the meta handling.

@rmccue

This comment has been minimized.

Copy link
Member Author

rmccue commented Apr 9, 2014

Pull request from @tobych is #128, and a great start.

@rmccue rmccue referenced this issue Apr 20, 2014

Merged

Add user endpoints #146

5 of 5 tasks complete

rachelbaker added a commit that referenced this issue Apr 30, 2014

Merge pull request #146 from WP-API/user-endpoints
Add endpoints to handle user management.  Closes #20.

kellbot pushed a commit to kellbot/WP-API that referenced this issue Aug 1, 2014

Merge pull request WP-API#146 from WP-API/user-endpoints
Add endpoints to handle user management.  Closes WP-API#20.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.