API Update: Access Datasheets from Octopart API V3

133 views
Skip to first unread message

andres

unread,
Jun 3, 2013, 2:15:30 PM6/3/13
to octopa...@googlegroups.com
Hi Everyone,

I'm happy to report that you can now access datasheets from Octopart API V3. Here's the blog post with the announcement:

http://octopart.com/blog/archives/2013/6/api-update%253A-access-datasheets-from-the-octopart-api

In addition to datasheets, we have added two new features which I'm very excited about: Show/Hide Directives and Slice Directives.

Show/Hide Directives are url arguments that you can use to control the size of API response objects by only requesting the fields that you need. For example, you can use the directives to only return MPNs and manufacturer brand names for each part matched in a call to the parts/match endpoint.

Slice Directives are url arguments that you can use to perform slice operations on lists. For example, you can choose to only return the first five offers matched in a parts/match request. Slice Directives are very useful for more find grained control over API response sizes where you want to limit the number of objects in a list.

I hope you like the new features we've added. Please let us know if you have any thoughts or suggestions!

Andres

Bryan Bishop

unread,
Jun 3, 2013, 2:38:35 PM6/3/13
to octopa...@googlegroups.com, Bryan Bishop, Andres Morey
On Mon, Jun 3, 2013 at 1:15 PM, andres <and...@octopart.com> wrote:
I'm happy to report that you can now access datasheets from Octopart API V3.

How are these datasheets returned? Are these parsed datasheets?

- Bryan
http://heybryan.org/
1 512 203 0507

Andres Morey

unread,
Jun 3, 2013, 2:48:07 PM6/3/13
to Bryan Bishop, octopa...@googlegroups.com
Hi Bryan,

The schema for a Datasheet object is described here:

There is some parsed out metadata (e.g. date_created, last_updated) described here:

Hope that helps! Let me know if you have any questions.

Andres
--
Andres Morey
Octopart Inc.
+1-415-254-2074

Checkout our new API!
http://octopart.com/api

Bryan Bishop

unread,
Jun 3, 2013, 2:57:54 PM6/3/13
to Andres Morey, Bryan Bishop, octopa...@googlegroups.com
On Mon, Jun 3, 2013 at 1:48 PM, Andres Morey <and...@octopart.com> wrote:
Hope that helps! Let me know if you have any questions.

I am sure it would be immediately obvious if I was to make an API request, but I haven't done this yet. The documentation presently says that the Datasheet object has "subtypes", and the value can be either "technical_drawing" or "application_note". But what else is provided by the API for this datasheet feature when you specify include[]=datasheet? Is there a url to a datasheet pdf file, and if so is it included in the "subtypes"?

Maybe if the case is that running curl to check the API reveals the answers to my questions, then perhaps a small example should be placed in the documentation showing a response with an ideal "datasheet" record?

Thank you!

Andres Morey

unread,
Jun 3, 2013, 3:02:12 PM6/3/13
to Bryan Bishop, octopa...@googlegroups.com
HI Bryan,

Thanks for the feedback. We'll add an example of a datasheet object to the documentation. The Datasheet objects inherits from "Asset" which contain urls, metadata, mimetype, etc. and are described here:


Andres

Bryan Bishop

unread,
Jun 3, 2013, 3:18:20 PM6/3/13
to Andres Morey, Bryan Bishop, octopa...@googlegroups.com
On Mon, Jun 3, 2013 at 2:02 PM, Andres Morey <and...@octopart.com> wrote:
Thanks for the feedback. We'll add an example of a datasheet object to the documentation. The Datasheet objects inherits from "Asset" which contain urls, metadata, mimetype, etc. and are described here:

Okay, I see now. Yes, inherting from Assets makes sense and resolves my questions. I just didn't notice the header text I guess. Thank you.

Andres Morey

unread,
Jun 3, 2013, 3:43:06 PM6/3/13
to Bryan Bishop, octopa...@googlegroups.com
Hi Bryan,

Thanks again for the feedback. We've added an example API response to the documentation:


Andres

Bryan Bishop

unread,
Jun 3, 2013, 3:59:40 PM6/3/13
to octopa...@googlegroups.com, Bryan Bishop, Andres Morey
On Mon, Jun 3, 2013 at 2:43 PM, Andres Morey <and...@octopart.com> wrote:
Thanks again for the feedback. We've added an example API response to the documentation:

That example looks great. Thanks for the fast update.

When I first looked, it wasn't obvious that EXAMPLE_KEY was a working example key (instead of only a placeholder) and that trying it would be successful. I don't have a good suggestion for emphasizing that the key actually works.

As for Datasheet inheriting from Asset, maybe a line under the <h3> element would be more immediately obvious? Maybe a <i>Inherits from..</i> message. I notice that none of the other types are documented as inheriting from any other type, so maybe other users will overlook the extra detail in the <h3> text like I did.

Really interesting feature, by the way. The main use case I am thinking of is dumping out technical documentation for the components of a project.
Message has been deleted

andres

unread,
Jun 4, 2013, 11:29:36 AM6/4/13
to octopa...@googlegroups.com, Bryan Bishop, Andres Morey
Hi Bryan,

Thanks again for the feedback. I added the inherited attributes to the Datasheet schema documentation to make the documentation easier to follow:

Andres
Reply all
Reply to author
Forward
0 new messages