PHPackages                             laraluke/statamic-api-select - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. laraluke/statamic-api-select

ActiveStatamic-addon[Utility &amp; Helpers](/categories/utility)

laraluke/statamic-api-select
============================

1.0.0(5y ago)3448↓100%[9 PRs](https://github.com/laraluke/statamic-api-select/pulls)PHPCI passing

Since Aug 7Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/laraluke/statamic-api-select)[ Packagist](https://packagist.org/packages/laraluke/statamic-api-select)[ RSS](/packages/laraluke-statamic-api-select/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)DependenciesVersions (12)Used By (0)

API Select Fieldtype addon for Statamic
=======================================

[](#api-select-fieldtype-addon-for-statamic)

Utilise API endpoints for your Select Fieldtype options.

License
-------

[](#license)

API Select requires a license.

You can purchase one at

You may use API Select without a license while Statamic is in [Trial mode](https://docs.statamic.com/knowledge-base/trial-mode).

Installation
------------

[](#installation)

Require it using Composer.

```
composer require laraluke/statamic-api-select

```

Publish the assets:

```
php artisan vendor:publish --provider="Laraluke\ApiSelectFieldtype\ServiceProvider"

```

Using the API Select Fieldtype
------------------------------

[](#using-the-api-select-fieldtype)

Add the fieldtype to your fieldset/blueprint. You will then need to configure the following settings:

#### Endpoint Type

[](#endpoint-type)

This is to define whether or not your endpoint value is a URL or a config variable.

#### Endpoint

[](#endpoint)

If your endpoint type is a URL your endpoint value will look like this:

```
https://jsonplaceholder.typicode.com/users

```

If your endpoint type is a config variable your endpoint value will look like this:

```
endpoints.users

```

and your `endpoints.php` file would look something like this:

```
return [
    'users' => 'https://jsonplaceholder.typicode.com/users',
];
```

#### Cache Duration

[](#cache-duration)

This is how long API requests will be cached for in minutes.

Set this value to 0 if you don't want to cache results.

#### Data Set Key

[](#data-set-key)

If your data set isn't in the top-level of your API response you can define it's location using dot syntax.

So if your API result looks like:

```
{
    "data": {
        "users": []
    }
}
```

You would set the data set key value to:

```
data.users

```

#### Item Key

[](#item-key)

Define the unique identifier to be used as the option value.

So if the iteration in your API result looks like this:

```
{
    "id": 1,
    "name": "Leanne Graham",
    "username": "Bret",
    "email": "Sincere@april.biz",
}
```

You might set your item key to:

```
id

```

#### Item Label

[](#item-label)

Define the value to be used as the option label.

So if the iteration in your API result looks like this:

```
{
    "id": 1,
    "name": "Leanne Graham",
    "username": "Bret",
    "email": "Sincere@april.biz",
}
```

You might set your item label to:

```
name

```

Using the API Select value in your templates
--------------------------------------------

[](#using-the-api-select-value-in-your-templates)

Let's assume your API select field handle is `api_select_users` API response is like so:

```
[
    {
        "id": 1,
        "name": "Leanne Graham",
        "username": "Bret",
        "email": "Sincere@april.biz",
    },
    {
        "id": 2,
        "name": "Ervin Howell",
        "username": "Antonette",
        "email": "Shanna@melissa.tv",
    }
]
```

#### Single-choice API Select

[](#single-choice-api-select)

```
{{ api_select_users.name }}

// Returns
Leanne Graham

```

#### Multi-choice API Select

[](#multi-choice-api-select)

```
{{ api_select_multi }}
    {{ name }}
{{ /api_select_multi }}

// Returns
Leanne Graham
Ervin Howell

```

###  Health Score

39

—

LowBetter than 86% of packages

Maintenance55

Moderate activity, may be stable

Popularity18

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2110d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/65ed117540a993c23db13d6b1a5ae628ab6d1b916adad6dc14bcdeaa819fe016?d=identicon)[laraluke](/maintainers/laraluke)

---

Top Contributors

[![laraluke](https://avatars.githubusercontent.com/u/64359191?v=4)](https://github.com/laraluke "laraluke (1 commits)")

### Embed Badge

![Health badge](/badges/laraluke-statamic-api-select/health.svg)

```
[![Health](https://phpackages.com/badges/laraluke-statamic-api-select/health.svg)](https://phpackages.com/packages/laraluke-statamic-api-select)
```

###  Alternatives

[maize-tech/laravel-markable

Laravel Markable

755229.4k](/packages/maize-tech-laravel-markable)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
