Skip to content
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

Enhance the ProjectUpdateResource for easier integration #306

Closed
zzgvh opened this issue Sep 17, 2013 · 6 comments
Closed

Enhance the ProjectUpdateResource for easier integration #306

zzgvh opened this issue Sep 17, 2013 · 6 comments

Comments

@zzgvh
Copy link
Contributor

zzgvh commented Sep 17, 2013

Commonsites want to use the API to populate their site with project updates and we have a similar use case on akvo.org itself. However it's hard (impossible without an API key) to access all data that is publicly available on the web pages of updates, specifically the user's full name and organisation affiliation.

@adriancollier
Copy link
Contributor

Even with a Key it's only possible to reach this information if the user is actually within their organisation.

I would prefer not to open the API so all of this information is public, but to promote the use of an API key, and then also ensure that all the necessary data is then available to them.

So, we should try to include this kind of feature improvement with the Network Partner option we are looking at here: #247

zzgvh added a commit that referenced this issue Sep 17, 2013
Update the dehydrate method of ConditionalFullToOneField.dehydrate to
use more modern code from tastypie, allowing the use of "__" references
in the "attribute" field option.
zzgvh added a commit that referenced this issue Sep 17, 2013
Add "full_name" field with the full name of the user posting the update.

Add "organisation_name" with the name of the organisation the user is
connected to.

Add "organisation" which is a fully working ToOneField to the
organisation of the user.

Add schema objects for "full_name" and "organisation_name" since they
are totally artificial fields.
@zzgvh
Copy link
Contributor Author

zzgvh commented Sep 17, 2013

We could easily limit the extra fields added above so they're only available if you access the API with a key.

@adriancollier
Copy link
Contributor

I think we need to do some more spec before we push the API key as there seems to be some difference in the impact for and against.

In the meantime, @zzgvh if these items are finished, can you please merge them into Develop so we can view the result?

@KasperBrandt
Copy link
Contributor

I think this issue is already covered in #463. The only thing is that '_extra' needs to be added in the link, e.g. http://rsr.akvo.org/api/v1/project_update_extra/4332/?format=json.

@zzgvh What do you think, can we remove this issue (and branch)?

@zzgvh
Copy link
Contributor Author

zzgvh commented May 15, 2014

Yes, the project_update_extra resource should cover the above needs too. I talked to @stellanl yesterday and the Up app needs more data that should be added to project_update_extra. The same goes for the needs of the data pulled to akvo.org. I'll document it in #463.

@KasperBrandt
Copy link
Contributor

Merged in #591

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

No branches or pull requests

4 participants