
Security News
Browserslist-rs Gets Major Refactor, Cutting Binary Size by Over 1MB
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
@serverless/serverless-event-gateway-plugin
Advanced tools
Serverless plugin that publishes your functions and subscriptions to Hosted Event Gateway.
Serverless plugin that publishes your functions and subscriptions to Hosted Event Gateway.
This is best used with the hosted version of the Event Gateway provided by Serverless, Inc. as a fully-managed service.
After you create an account, you'll need two things: an Access Key and an Application URL.
Get an Access Key in the Access Control
section, and save it to your clipboard:
Then, grab the URL for one of your Applications:
Finally, save both of these to your serverless.yml
:
# serverless.yml
custom:
eventgateway:
url: tenant-yourapp.slsgateway.com
accessKey: AKmyKey1234
...
You're all set!
Looking for an example to get started? Check out the Getting Started Example to deploy your first service to the Event Gateway.
Create a new Serverless service and change into the directory.
Install the plugin: (needs Node version 7+)
$ npm install --save-dev @serverless/serverless-event-gateway-plugin
Enter the necessary plugin and config in serverless.yml
:
# serverless.yml
service: my-service
custom:
eventTypes:
http.request:
eventgateway:
url: myorg-app.slsgateway.com
accessKey: <yourkey>
# To use self-hosted Event Gateway, use the following
# url: http://localhost:4000
plugins:
- "@serverless/serverless-event-gateway-plugin"
provider:
name: aws
runtime: python3.6
stage: dev
region: us-west-2
...
Wire up functions with an eventgateway
event type:
# serverless.yml
functions:
hello:
handler: handler.hello
events:
- eventgateway:
type: sync
eventType: http.request
path: /hello
method: GET
goodbye:
handler: handler.goodbye
events:
- eventgateway:
type: sync
eventType: http.request
path: /goodbye
method: GET
Deploy, then invoke your function(s):
$ sls deploy
....
$ curl -X GET https://myspace.slsgateway.com/hello
...
$ curl -X GET https://myspace.slsgateway.com/goodbye
...
View your space configuration with sls gateway dashboard
:
$ sls gateway dashboard
Event Gateway
space: myspace
endpoint: https://myspace.slsgateway.com
Functions
┌─────────────────────────────────┬───────────┬────────────────────────────────────────────────────────────────────────────────┐
│ Function Id │ Region │ ARN │
├─────────────────────────────────┼───────────┼────────────────────────────────────────────────────────────────────────────────┤
│ my-service-dev-hello │ us-east-1 │ arn:aws:lambda:us-east-1:111111111111:function:my-service-dev-hello │
├─────────────────────────────────┼───────────┼────────────────────────────────────────────────────────────────────────────────┤
│ my-service-dev-goodbye │ us-east-1 │ arn:aws:lambda:us-east-1:111111111111:function:my-service-dev-goodbye │
└─────────────────────────────────┴───────────┴────────────────────────────────────────────────────────────────────────────────┘
Subscriptions
┌────────┬─────────────────────────────────┬────────┬───────────────────────┐
│ Event │ Function ID │ Method │ Path │
├────────┼─────────────────────────────────┼────────┼───────────────────────┤
│ http │ my-service-dev-hello │ GET │ /myspace/hello │
├────────┼─────────────────────────────────┼────────┼───────────────────────┤
│ http │ my-service-dev-goodbye │ GET │ /myspace/goodbye │
└────────┴─────────────────────────────────┴────────┴───────────────────────┘
Core concepts:
Event concepts:
Auth concepts:
https://myorg-my-app.slsgateway.com
.FAQs
Serverless plugin that publishes your functions and subscriptions to Hosted Event Gateway.
The npm package @serverless/serverless-event-gateway-plugin receives a total of 4 weekly downloads. As such, @serverless/serverless-event-gateway-plugin popularity was classified as not popular.
We found that @serverless/serverless-event-gateway-plugin demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.