PHPackages                             supercool/fetch - 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. supercool/fetch

ActiveCraft-plugin

supercool/fetch
===============

A field type to embed video for Craft CMS

4.0.1(1y ago)027.4k↓40.9%MITPHP

Since Aug 10Pushed 8mo ago3 watchersCompare

[ Source](https://github.com/supercool/fetch)[ Packagist](https://packagist.org/packages/supercool/fetch)[ RSS](/packages/supercool-fetch/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)Dependencies (1)Versions (9)Used By (0)

Fetch plugin for Craft CMS 3.x
==============================

[](#fetch-plugin-for-craft-cms-3x)

A field type to embed videos for Craft CMS

Requirements
------------

[](#requirements)

This plugin requires Craft CMS 3.0.0 or later.

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

[](#installation)

To install the plugin, follow these instructions.

1. Open your terminal and go to your Craft project:

    ```
     cd /path/to/project

    ```
2. Then tell Composer to load the plugin:

    ```
     composer require supercool/fetch

    ```
3. In the Control Panel, go to Settings → Plugins and click the “Install” button for Fetch.

Usage
-----

[](#usage)

Supported providers (links taken at random from site for example purposes):

- Vimeo - Videos (e.g )
- Twitter - Tweets (e.g )
- Youtube - Videos (e.g )
- Flickr - Pictures (e.g )
- Soundcloud - Audio (e.g )
- Instagram - Posts, NOT STORIES (e.g )

### Settings

[](#settings)

#### Plugin

[](#plugin)

"validateUrlsOnSave" - Lightswitch - When disabled, elements will be able to save even if the link is invalid, or the service is non-responsive. this can be used in the case of another service issue, similar to when linode was blacklisted by youtube.

#### Field

[](#field)

Each available provider will have a lightswitch that allows you to enable/disable them for the field. This will default to enabled.

### Twig

[](#twig)

If the field is not populated, it will return either null or an empty string.

If the field is populated and has no issues, it will return a FetchModel (detailed below)

If the field is populated and has errors getting the embed, it will return a FetchModel containing no data

#### FetchModel

[](#fetchmodel)

Available methods:

```
{{ field.success }}
or
{{ field.getSuccess() }}

```

Returns a boolean, false if there were any errors fetching the embed, true if there weren't

---

```
{{ field.errorMessage }}
or
{{ field.getErrorMessage() }}

```

If the embed fetch was unsuccessful, returns the error message, else returns null

---

```
{{ field.twig }}
or
{{ field.getTwig() }}

```

Returns the twig for the embed, will be an empty string if there was an error fetching the embed

---

```
{{ field.html }}
or
{{ field.getHtml() }}

```

Identical to `.twig / .getTwig()`, but returns the markup as html rather than twig\_markup

---

```
{{ field.provider }}
or
{{ field.getProvider() }}

```

Returns the provider identified for the url, in lowercase (e.g youtube), or null if there was an error

---

```
{{ field.object }}
or
{{ field.getObject() }}

```

Returns the data received from the oembed api, or null if there was an error.

This data will vary from api to api, and can best be found by looking at the relevant api docs. e.g  for instagram.

---

Brought to you by [Supercool Ltd](http://www.supercooldesign.co.uk/)

###  Health Score

42

—

FairBetter than 90% of packages

Maintenance51

Moderate activity, may be stable

Popularity26

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 50% 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

Every ~458 days

Recently: every ~520 days

Total

6

Last Release

543d ago

Major Versions

1.0.3 → 4.0.02023-09-22

### Community

Maintainers

![](https://www.gravatar.com/avatar/a2e814e34ae462e254dfcf16887de782be93f37206262aa80e978bf42dc62915?d=identicon)[supercool](/maintainers/supercool)

---

Top Contributors

[![Nav33d](https://avatars.githubusercontent.com/u/4228466?v=4)](https://github.com/Nav33d "Nav33d (4 commits)")[![jamie-s-white](https://avatars.githubusercontent.com/u/137078049?v=4)](https://github.com/jamie-s-white "jamie-s-white (3 commits)")[![NickThompson1993](https://avatars.githubusercontent.com/u/43541207?v=4)](https://github.com/NickThompson1993 "NickThompson1993 (1 commits)")

---

Tags

cmsCraftcraftcmscraft-pluginfetchcraftcms3supercool

### Embed Badge

![Health badge](/badges/supercool-fetch/health.svg)

```
[![Health](https://phpackages.com/badges/supercool-fetch/health.svg)](https://phpackages.com/packages/supercool-fetch)
```

###  Alternatives

[nystudio107/craft-seomatic

SEOmatic facilitates modern SEO best practices &amp; implementation for Craft CMS 5. It is a turnkey SEO system that is comprehensive, powerful, and flexible.

1741.4M46](/packages/nystudio107-craft-seomatic)[verbb/image-resizer

Resize assets when they are uploaded.

127269.1k7](/packages/verbb-image-resizer)[verbb/tablemaker

Create customizable and user-defined table fields.

40168.8k1](/packages/verbb-tablemaker)[jalendport/craft-fetch

Utilise the Guzzle HTTP client from within your Craft templates.

2327.6k1](/packages/jalendport-craft-fetch)[verbb/hyper

A user-friendly links field for Craft.

24130.9k9](/packages/verbb-hyper)[acclaro/translations

Easily launch and manage multilingual Craft websites without having to copy/paste content or manually track updates.

1229.5k](/packages/acclaro-translations)

PHPackages © 2026

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