Skip to main content
PATCH
/
caches
/
{cache}
Update cache
curl --request PATCH \
  --url https://cloud.laravel.com/api/caches/{cache} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "size": "250mb",
  "auto_upgrade_enabled": true,
  "is_public": true,
  "eviction_policy": "allkeys-lru"
}
'
{
  "data": {
    "id": "<string>",
    "type": "caches",
    "attributes": {
      "name": "<string>",
      "type": "upstash_redis",
      "status": "creating",
      "region": "us-east-2",
      "size": "250mb",
      "auto_upgrade_enabled": true,
      "is_public": true,
      "created_at": "2023-11-07T05:31:56Z",
      "connection": {
        "hostname": "<string>",
        "port": 123,
        "protocol": "redis",
        "username": "<string>",
        "password": "<string>"
      }
    },
    "relationships": {
      "environments": {
        "data": [
          {
            "type": "environments",
            "id": "<string>"
          }
        ]
      }
    }
  },
  "included": [
    {
      "id": "<string>",
      "type": "environments",
      "links": {
        "self": {
          "href": "<string>",
          "rel": "<string>",
          "describedby": "<string>",
          "title": "<string>",
          "type": "<string>",
          "hreflang": "<string>",
          "meta": {}
        }
      },
      "attributes": {
        "name": "<string>",
        "slug": "<string>",
        "status": "deploying",
        "created_from_automation": true,
        "vanity_domain": "<string>",
        "php_major_version": "8.2",
        "build_command": "<string>",
        "node_version": "20",
        "deploy_command": "<string>",
        "uses_octane": true,
        "uses_push_to_deploy": true,
        "uses_deploy_hook": true,
        "environment_variables": [
          {
            "key": "<string>",
            "value": "<string>"
          }
        ],
        "network_settings": {
          "cache": {
            "strategy": "<string>"
          },
          "response_headers": {
            "frame": "<string>",
            "content_type": "<string>",
            "hsts": {
              "max_age": 123,
              "include_subdomains": true,
              "preload": true
            }
          },
          "firewall": {
            "bot_categories": [
              "academic_research"
            ],
            "rate_limit": {
              "429": true,
              "level": "challenge",
              "per_minute": 100,
              "4xx": true
            },
            "under_attack_mode_started_at": "<string>",
            "block_path": true
          },
          "content_converter": true
        },
        "created_at": "2023-11-07T05:31:56Z"
      },
      "relationships": {
        "application": {
          "data": {
            "type": "applications",
            "id": "<string>"
          }
        },
        "branch": {
          "data": {
            "type": "branches",
            "id": "<string>"
          }
        },
        "deployments": {
          "data": [
            {
              "type": "deployments",
              "id": "<string>"
            }
          ]
        },
        "currentDeployment": {
          "data": {
            "type": "deployments",
            "id": "<string>"
          }
        },
        "domains": {
          "data": [
            {
              "type": "domains",
              "id": "<string>"
            }
          ]
        },
        "primaryDomain": {
          "data": {
            "type": "domains",
            "id": "<string>"
          }
        },
        "instances": {
          "data": [
            {
              "type": "instances",
              "id": "<string>"
            }
          ]
        },
        "database": {
          "data": {
            "type": "databaseSchemas",
            "id": "<string>"
          }
        },
        "cache": {
          "data": {
            "type": "caches",
            "id": "<string>"
          }
        },
        "buckets": {
          "data": [
            {
              "type": "filesystems",
              "id": "<string>"
            }
          ]
        },
        "websocketApplication": {
          "data": {
            "type": "websocketApplications",
            "id": "<string>"
          }
        }
      }
    }
  ]
}

Documentation Index

Fetch the complete documentation index at: https://cloud.laravel.com/docs/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

The Bearer Token generated on the Cloud UI.

Path Parameters

cache
string
required

The cache identifier

Body

application/json
name
string
Required string length: 3 - 40
Pattern: ^[a-z0-9_-]+$
size
enum<string>
Available options:
250mb,
1gb,
2.5gb,
5gb,
12gb,
50gb,
100gb,
500gb,
valkey-pro.250mb,
valkey-pro.1gb,
valkey-pro.2.5gb,
valkey-pro.5gb,
valkey-pro.12gb,
valkey-pro.25gb,
valkey-pro.50gb,
elasticache.cache.r7g.large,
elasticache.cache.r7g.xlarge,
elasticache.cache.r7g.2xlarge,
elasticache.cache.r7g.4xlarge,
elasticache.cache.r7g.8xlarge,
elasticache.cache.r7g.12xlarge,
elasticache.cache.r7g.16xlarge
auto_upgrade_enabled
boolean
is_public
boolean
eviction_policy
enum<string>

Only available for Valkey.

Available options:
allkeys-lru,
noeviction,
volatile-lru,
allkeys-random,
volatile-random,
volatile-ttl,
allkeys-lfu,
volatile-lfu

Response

CacheResource

data
CacheResource · object
required
included
EnvironmentResource · object[]