Functions Modules
The following modules are available in Functions:
Library Name | Description |
---|---|
XHR | The XHR library is used to enable the developer to send HTTP or HTTPS requests to a remote web server and load the response data back into a Function. This library is perfect for third-party authentication or triggering webhooks from a Function. |
KV Store | This library allows access to the KV store . It's a persistent key value store that acts as a database for your Functions . The KV store database is globally distributed and eventually consistent. Data in the KV store is shared at a subscribe key level. |
Advanced Math | Global (lat-long) coordinate and geometry functions. |
Crypto | The Crypto library provides encryption and decryption functionality in an Function. |
Utils | Simple utility functions that didn't belong anywhere else. |
Codec/auth | Provides an encoder for HTTP basic auth credentials. |
Codec/base64 | Provides an encoder and decoder for Base64 strings. |
Codec/query_string | Provides an encoder and decoder for URI query parameters. |
PubNub | The PubNub library allows you to leverage many of the client SDK features supported by the PubNub Platform. |
vault | Read-only database to retrieve secrets. |
Features not yet available in Functions
Some JavaScript features that you may expect to see, but aren't yet available in Functions:
- Native node modules
- async/await
- Access to process and some other global variables
- Ability to install third-party modules via npm