Example Request

from metaphor_python import Metaphor
metaphor = Metaphor(os.getenv("METAPHOR_API_KEY"))

contents_result = metaphor.get_contents(["fRZd_DYpWEAxrLhfv2ctsg"])
first_result = contents_result.contents[0]
curl --request GET \
     --url https://api.metaphor.systems/contents?ids=fRZd_DYpWEAxrLhfv2ctsg \
     --header 'accept: application/json' \
     --header 'x-api-key: METAPHOR_API_KEY'

Example Response

> <div><div><article><div><p>The <strong><code>Object</code></strong> type represents one of <a href="/en-US/docs/Web/JavaScript/Data_structures">JavaScript's data types</a>. It is used to store various keyed collections and more complex entities. Objects can be created using the <a href="/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/Object"><code>Object()</code></a> constructor or the <a href="/en-US/docs/Web/JavaScript/Reference/Operators/Object_initializer">object initializer / literal syntax</a>.</p></div><section><h2><a href="#description">Description</a></h2><div><p>Nearly all <a href="/en-US/docs/Web/JavaScript/Data_structures#objects">objects</a> in JavaScript are instances of <a href="/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"><code>Object</code></a>; a typical object inherits properties (including methods) from <code>Object.prototype</code>, although these properties may be shadowed (a.k.a. overridden). The only objects that don't inherit from <code>Object.prototype</code> are those with <a href="#null-prototype_objects"><code>null</code> prototype</a>, or descended from other <code>null</code> prototype objects.</p>
>
> <p>Changes to the <code>Object.prototype</code> object are seen by <strong>all</strong> objects through prototype chaining, unless the properties and methods subject to those changes are overridden further along the prototype chain. This provides a very powerful although potentially dangerous mechanism to override or extend object behavior. To make it more secure, <code>Object.prototype</code> is the only object in the core JavaScript language that has <a href="/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/setPrototypeOf#description">immutable prototype</a> — the prototype of <code>Object.prototype</code> is always <code>null</code> and not changeable.</p></div></section><section><h3><a href="#object_prototype_properties">Object prototype properties</a></h3><div><p>You should avoid calling any <code>Object.prototype</code> method, especially those that are not intended to be polymorphic (i.e. only its initial behavior makes sense and no descending object could override it in a meaningful way). All objects descending from <code>Object.prototype</code> may define a custom own property that has the same name, but with entirely different semantics from what you expect. Furthermore, these properties are not inherited by <a href="#null-prototype_objects"><code>null</code>-prototype objects</a>. All modern JavaScript utilities for working with objects are <a href="#static_methods">static</a>. More specifically:</p>
> <ul>
>  <li><a href="/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/valueOf"><code>valueOf()</code></a>, <a href="/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/toString"><code>toString()</code></a>, and <a href="/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/toLocaleString"><code>toLocaleString()</code></a> exist to be polymorphic and you should expect the object to define its own implementation with se

See Basic search for an example of searching and getting contents.