Build a BOM Tool with the Octopart API

Created: April 28, 2021
Updated: October 10, 2024
electronic components

Do you need to determine the availability of critical components? Would you like to match many line items with a list of manufacturer and part numbers at once? If the answer is yes to both questions, please continue reading.

We especially recommend exploring the multi-match function to build a custom BOM tool for academic or research purposes. The following tip can save you and your team resources and help you search for accurate data faster.

With the multi match field, you can set a variety of arguments, such as filtering by parts that are in stock and have the latest pricing. You can explore the rest of the options in our API Documentation.

Persona 2b

This function can also be useful when experimenting with cool projects (speaking to you hobby engineers!). Many of our users view the API as a way to optimize the cost of a BOM for a given volume where there are multiple sources for every part.

“Pro Tips:”

  1. Search for multiple MPNs in a single query to achieve a BOM Tool-like experience.

  2. The following query example can help support complex operations like aggregation, sorting, filtering, and pagination.

{
  multi_match(
    queries: [
      { manufacturer: "Texas Instruments", mpn: "LM317T" },
      { mpn: "SN74S74N", reference: "test", limit: 5 }
    ]
  ) {
    hits
    reference
    parts {
      id
      slug
      mpn
      manufacturer {
        name
      }
    }

If this is your first time building a BOM tool, you can practice your queries in the GraphQL Playground. You will find further resources, such as documentation you can easily reference from the side panel.

Persona 2c

For design purposes, you can also include part specifications in your query such as Lifecycle Status as found in the Octopart BOM sample.

Persona 2d

We hope you found this information helpful. If you need assistance managing your plan or have questions about our documentation, please contact us at api@octopart.com.

Related Resources

Back to Home
Thank you, you are now subscribed to updates.