> For the complete documentation index, see [llms.txt](https://alphavantage-api.marcelwagner.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://alphavantage-api.marcelwagner.dev/deep-dive/core.md).

# Core

The `Core` class provides methods to interact with essential endpoints of the Alphavantage API. It includes methods for fetching global quotes and searching for stock symbols.

### Methods

#### 1. Quote Endpoint

Fetches the latest global quote for a given stock symbol.

**Signature:**

```php
public function quoteEndpoint(string $symbol): array
```

**Parameters:**

* `symbol` (string): The stock symbol to fetch the global quote for.

**Returns:**

* `array`: An array containing the global quote data.

**Exceptions:**

* `ApiVolumeReached`
* `ConnectionException`

#### 2. Search

Searches for stock symbols based on keywords.

**Signature:**

```php
public function search(string $keywords): array
```

**Parameters:**

* `keywords` (string): The keywords to search for stock symbols.

**Returns:**

* `array`: An array containing the search results.

**Exceptions:**

* `ApiVolumeReached`
* `ConnectionException`

***

The `Core` class is designed to provide essential functionalities using the Alphavantage API. The `quoteEndpoint` method fetches the latest global quote for a given stock symbol, while the `search` method allows for searching stock symbols based on keywords. Be sure to handle the possible exceptions when using these methods to ensure robust error handling in your application.
