npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@mayurajs/deploy-agentcore

v1.2.0

Published

Amazon Bedrock AgentCore Runtime as a mayura deploy target: an ARM64 image serving its HTTP contract, then the runtime update.

Readme

@mayurajs/deploy-agentcore

Amazon Bedrock AgentCore Runtime as a mayura deploy target. A Mayura agent behind AgentCore's HTTP contract, as an ARM64 image, released by updating the runtime and waiting until it is ready.

npm install --save-dev @mayurajs/deploy-agentcore
mayura deploy init --target agentcore --apply
# Once: create the runtime (aws bedrock-agentcore-control create-agent-runtime) from a first image, then set
# targets.agentcore.region, agentRuntimeId and roleArn in mayura.deploy.json.
mayura deploy --target agentcore              # prints the plan and its digest
mayura deploy --target agentcore --apply --confirm <digest>

Your module (src/agentcore.ts, compiled to dist/src/agentcore.js) exports invoke(payload, { sessionId, signal }). It receives each invocation's JSON payload and returns a JSON value, or a Response (an SSE stream, for example), which is passed through:

import { createRuntime } from 'mayura';
import { assistant } from './assistant.js';

const runtime = createRuntime({
  profile: 'ephemeral',
  permissions: { allow: ['model:openai.responses'] },
  scope: { principalId: 'agentcore', projectId: 'refunds' },
  limits: { maxCostMicros: 100_000, maxDurationMs: 300_000 },
});

export async function invoke(payload: { readonly question: string }, context: { readonly sessionId?: string; readonly signal: AbortSignal }) {
  const run = runtime.submit(assistant, { input: payload });
  context.signal.addEventListener('abort', () => run.cancel(), { once: true }); // the caller went away
  return run.result();
}

deploy init writes:

  • deploy/agentcore/server.mjs: the AgentCore HTTP contract on 0.0.0.0:8080.
    • POST /invocations calls invoke. Bodies are at most 10 MiB, and errors reach the caller without their text.
    • GET /ping answers HealthyBusy while invocations run, so AgentCore keeps the session alive.
    • AgentCore authenticates callers (SigV4 or OAuth) before requests reach the container.
  • deploy/agentcore/Dockerfile: the image that runs the server.
  • deploy/agentcore/migrate.mjs: for apps with storage.

A release:

  1. Checks the signed-in account.
  2. Builds the image for linux/arm64 without a provenance attestation, and pushes it.
  3. With migrate: true, migrates from your machine with the DATABASE_URL in your environment.
  4. Updates the runtime to the image, with its role, network configuration and environment.
  5. Waits until the runtime is READY. UPDATE_FAILED fails the release.

Settings in mayura.deploy.json under targets.agentcore:

  • region, agentRuntimeId and roleArn;
  • network: { "mode": "PUBLIC" }, or a VPC with its subnets and security groups;
  • environment: set on every update. Plain configuration only, such as a secret's ARN for your module to read with the runtime's role; never secret values.
  • migrate (false);
  • module.

The AWS CLI uses its own credentials; Mayura reads none. Building ARM64 images on an x86 machine needs Docker's emulation, which Docker Desktop includes.

See Deploy with mayura deploy. Apache-2.0.