|
It seems to have been down for a while...[^] I checked it quite often since that was posted by ProgramFOX (I saw the message shortly after he posted it) and it was always down for me.
What do you get when you cross a joke with a rhetorical question?
The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism.
Do questions with multiple question marks annoy you???
|
|
|
|
|
Matthew Dennis wrote: However, I've just noticed that the API site is down and will get it going.
It's been up for a few days, but now I'm getting a runtime error again. Do you want to take a look at that? Thanks!
The quick brown ProgramFOX jumps right over the Lazy<Dog> .
|
|
|
|
|
You can use the websiteLink property to get the article from the CodeProject website.
|
|
|
|
|
I know I can do that - however, what comes across will not be an optimal format for the types of app I am hoping to develop out of this. Was it really something that couldn't be answered back in May?
This space for rent
|
|
|
|
|
Trying to GET from this URL: https://api.codeproject.com/v1/Forum/1159/0?page=1 , which is a valid one according to the docs, I get a 404 Not Found error.
Can you please take a look at this?
[Edit]
It does work when I replace 0 with messages , but the API docs say that 0 is a valid ForumDisplayMode.
The quick brown ProgramFOX jumps right over the Lazy<Dog> .
modified 15-May-15 6:03am.
|
|
|
|
|
Yes, it is the name, "Messages" or "Threads", that you use, not the value. I'll update the documentation.
|
|
|
|
|
|
I've added syntax highlighting to the API Documentation and the code samples.
|
|
|
|
|
Hi Matthew, is there any sort of list for upcoming APIs and features.
Can we see somewhere the plans for the future API development or maybe what is in your current roadmap?
Also is there any chance the API that I suggested (v1/{userId}/answers?page={page}, see Some suggestions for API enhancements below) would be available in a relative near future?
|
|
|
|
|
Unfortunately, we run a pretty lean shop here at CodeProject Central and I'm working on some performance and scalability improvements for the main site.
These changes may/will affect the API, so I'm holding off on any non-critical or non-trivial changes.
I saw your other post, and it looks like you want me to implement OData plus a couple of new APIs.
I've got it bookmarked for when I get time to work on new stuff for the API.
|
|
|
|
|
The API downloads appear to be out of action. I just tried to download various .zip files but they are all coming up with FNF errors.
|
|
|
|
|
Do you mean downloading the samples? I can download them fine.
The quick red ProgramFOX jumps right over the Lazy<Dog> .
|
|
|
|
|
Hmm. Definitely not working for me. I will wait a bit and try again.
|
|
|
|
|
Well that was odd. I had to log out and log back in to download the samples.
|
|
|
|
|
Glad it is working again.
Just to understand what went wrong, what browser & version are you using?
|
|
|
|
|
Latest version of Chrome on Windows 8.1.
|
|
|
|
|
I'm currently working on small POC website that shows CodeProject member's Q&A tags statistic (if interested it is available here) and while building it I collected few suggestions which I hope you'll find interesting and/or useful.
- First the easy one, in API documentations on few places the CodeProject APIs are referred as HTML services.
I think this should be HTTP services or better jet RESTful services.
- Somewhat common practice for defining a response's format is to add a format's extension termination on the URL to identify data type you want to request from the server, for example like the following:
v1/my/articles.xml?page={page}
v1/my/articles.json?page={page}
Now whether this is truly a RESTful approach or a best practice is debatable, but as it is now there is a problem of mixing two conventions. You see the versioning does not follow the convention that setting the result format uses. In order for versioning to follow the same convention (a true RESTful approach) it should also be defined in Media Type header, for example like the following:
"application/json;application&v=1"
Nevertheless I must say I don't see any downfall in supporting both approaches, as long as the priorities and the used default values are documented.
- Regarding the MY API, most (if not all) of these currently available GET APIs are publicly available resources. I mean every CodeProject member can look at the other member's Questions, Answers, Articles, etc. so it just feels natural to me that Client Credentials Grant should be required here, not Authorization Code Grant.
Nevertheless I'm not suggesting to change the current MY API (because I presume it is likely that you want to add follow-up PUT, POST, etc. APIs here), instead I'm suggesting to add something like the following:
v1/{userId}/answers?page={page}
v1/{userId}/articles?page={page}
And this API should work on Client Credentials Grant or Implicit Grant flow.
- Regarding the pagination, pageSize should definitely be available for querying together with page and you could specify the pageSize value limitation in the documentation.
So something like this should be supported:
v1/my/answers?page={page}&pageSize={pageSize}
Also I believe a very useful thing could be to provide First, Last, Next and Previous resource locations in PaginationInfo so that the pagination can be processed continuously from the response itself.
For example for the following API:
v1/my/answers?page=3
Could result into something like the following:
"pagination": {
"page": 3,
"pageSize": 25,
"totalPages": 5,
"totalItems": 25,
"first" : { "href" : "https://api.codeproject.com/v1/my/answers?page=1" },
"prev" : { "href" : "https://api.codeproject.com/v1/my/answers?page=2" },
"next" : { "href" : "https://api.codeproject.com/v1/my/answers?page=4" },
"last" : { "href" : "https://api.codeproject.com/v1/my/answers?page=5" },
}
Or maybe something like this:
<Pagination>
<Page>3</Page>
<PageSize>25</PageSize>
<TotalPages>5</TotalPages>
<TotalItems>25</TotalItems>
<link rel="first" href="https://api.codeproject.com/v1/my/answers?page=1" />
<link rel="prev" href="https://api.codeproject.com/v1/my/answers?page=2" />
<link rel="next" href="https://api.codeproject.com/v1/my/answers?page=4" />
<link rel="last" href="https://api.codeproject.com/v1/my/answers?page=5" />
</Pagination>
- Partial returned result, so instead of receiving a full result and filtering out the necessary data we could do something like this:
v1/my/answers?page=3&fields=pagination(totalItems),items(id,summary)
And receive only the following:
{
"pagination": {
"totalItems": 2
},
"items": [
{
"id": "100",
"summary": "First sample item."
},
{
"id": "200",
"summary": "Second sample item."
}
]
}
I hope any of these you will find useful, if you don't mind these type of suggestions let me know and I will continue collecting them and posting here afterword.
|
|
|
|
|
Hi,
I just thought to share with you a sample application with a portable library for CodeProject API Wrapper.
C# CodeProject API Wrapper[^]
Ranjan.D
|
|
|
|
|
Hi,
I just have a small question on non-redirect OAuth Flow.
I have registered in CodeProject Web API Client Settings with a dummy HTTPS URL.
When I am using the client id and secret key with in a console application, I do get the access token but while making a request, say to get my articles, the request fails with a Unauthorized Access.
Currently it works only for other API's that is the general CodeProject API but it's failing for My API.
Thanks,
Ranjan.D
modified 21-Feb-15 17:58pm.
|
|
|
|
|
|
Currently as I understood there's no way to filter the articles by date range when we are using GetArticles API.
Could you incorporate the article filtering by created and/or modified date in addition to other filters?
I will be happy to see these changes. I would rather use it in IOT Challenge
Thanks,
Ranjan.D
modified 12-Feb-15 17:43pm.
|
|
|
|
|
Hi,
I'm trying to get an access token and sends a request for authorization:
https://api.codeproject.com/Account/Authorize?client_id=92mWWELc2DjcL-6tu7L1Py6yllleqSCt&redirect_uri=http%3A%2F%2Foauthproxy.nemiro.net%2F&response_type=code
But the server returns an error:
invalid_request
Why?
PS: For demo data no errors:
https://api.codeproject.com/Account/Authorize?client_id=JkOnJ9zIQ1vWvP3FvsJVx-3iOnSd-6a-&redirect_uri=https%3A%2F%2Fapi.codeproject.com%2FSamples%2FMyApi%2F&response_type=code
Docendo Discimus
|
|
|
|
|
Your redirect url must start with https:// for security reasons.
|
|
|
|
|
Yes! It works!
Thanks!
Docendo Discimus
|
|
|
|
|
When fetching the newest questions through the API, for 5/25 questions, the author name was empty and the ID was 0:
[{"name":"","id":0}]
That's weird, because I checked and the user accounts are not deleted or something.
It seems like all members with the name "Member NNNNNN" are returned like this.
The quick red ProgramFOX jumps right over the Lazy<Dog> .
|
|
|
|