Skip to content

Commit

Permalink
source/includes: minor wording updates
Browse files Browse the repository at this point in the history
  • Loading branch information
postables committed Oct 31, 2019
1 parent 33ad5f9 commit 1e509c2
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 12 deletions.
2 changes: 1 addition & 1 deletion source/includes/account/_account_management.md
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ Javascript code here

`https://api.temporal.cloud/v2/account/upgrade`

Used to upgrade your account from free tier to the first non-free tier known as `Light`. When upgrading from a free account you are not eligible to downgrade your account. When upgrading your account, we allocate free $0.115USD worth of your credits, enough to pay for 0.5GB of storage for 1 month.
Used to upgrade your account from the free tier to the non-free tier known as `Paid`. After upgrading you are not allowed to downgrade and this is an irreversible action. Only in rare circumstances wil we allow individuals to downgrade.

## GET credits

Expand Down
6 changes: 3 additions & 3 deletions source/includes/ipfs/_ipfs_api.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Our IPFS HTTP APIs reverse proxy allows you to talk directly to the IPFS node AP

This endpoint is compatible with a majority of the IPFS HTTP API libraries, such as [js-ipfs-http-client](https://github.com/ipfs/js-ipfs-http-client). If you want to use `go-ipfs-api`, we maintain a [fork](https://github.com/RTradeLtd/go-ipfs-api) that allows you to insert an authentication header with your API calls.

This feature is experimental, and only available in the development environment. To access this feature, point your clients to `https://dev.api.ipfs.temporal.cloud`
To access this feature, point your clients to `https://api.ipfs.temporal.cloud`

## Authentication

Expand Down Expand Up @@ -58,8 +58,8 @@ Methods that take input will validate all parameters. Any parameter that fails v

## Hold Times

Hold times are used to indicate how many months a file, or pin should be held onto by our nodes. Free accounts are limited to 1 month maximum pin times, while non-free accounts are limited to 2 month maximum pin times.
Hold times are used to indicate how many months a file, or pin should be held onto by our nodes. Free accounts are limited to 1 month maximum pin times, while non-free accounts are limited to 2 year maximum pin times.

## Upload Sizes

When uploading files, all accounts are limited to a 1GB max file size. When encrypting files, free accounts are limited to a maximum file size of 275MB, while non-free accounts are limited to 1GB.
When uploading files, all accounts are limited to a 2GB max file size. When encrypting files, free accounts are limited to a maximum file size of 275MB, while non-free accounts are limited to 2GB.
2 changes: 1 addition & 1 deletion source/includes/ipfs/_public_network.md
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ Javascript code here

`https://api.temporal.cloud/v2/ipfs/public/pin/:hash/extend`

Used to extend the hold time of an existing IPFS pin of yours, up to the specified number of months. The total hold time for free accounts must be 1 month (including after extension), while non-free accounts is 2 years (including after extension)
Used to extend the hold time of an existing IPFS pin of yours, up to the specified number of months. The total hold time for free accounts must be 1 month (including after extension), while paid accounts is 2 years (including after extension)

### Parameters

Expand Down
25 changes: 18 additions & 7 deletions source/includes/ipfs/_reverse_proxy.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,22 @@
# IPFS HTTP API Proxy

The IPFS HTTP API reverse proxy uses a customized proxy solution developed in-house specificaly for the IPFS HTTP API. It is compatible with all IPFS HTTP API libraries, as long as they provide the ability for you to insert the JWT generated by Temporal into the authentication header.

To access this endpoint, all you need to do is point your clients to `https://dev.api.ipfs.temporal.cloud`
The IPFS HTTP API reverse proxy uses a customized proxy solution developed in-house specificaly for the IPFS HTTP API. It is compatible with all IPFS HTTP API libraries, as long as they provide the ability for you to insert the JWT generated by Temporal into the authentication header, as it uses the same authentication methods that Temporal's HTTP API uses.

Before using this API please read in detail how it works.

For a list of IPFS HTTP API calls that are white-listed when using this endpoint, please see the following [gist](https://gist.github.com/postables/55be1cf00e8ffafff6e663c198bf6482) which will be updated whenever calls are added/removed
Endpoint URLs:

* Production `https://api.ipfs.temporal.cloud`
* Development `https://dev.api.ipfs.temporal.cloud`

For a list of IPFS HTTP API calls that are white-listed when using this endpoint, please see the following [gist](https://gist.github.com/postables/55be1cf00e8ffafff6e663c198bf6482) which will be updated whenever calls are added/removed.

Usage of this API is tied into the billing system of Temporal, so you will need a valid Temporal account to use this API. Any API calls that involve storing data, such as `object/new`, `object/set-data`, `dag/put`, etc.. will trigger pinning of the data for **1 month**.

If your account is a free account, we will make sure that the size of the data won't breach the 3GB free storage amount. If it does, the API call will be reverted and you'll receive an error message. If your account is a paid account, we will make sure that your account has enough credits to cover storing the data for 1 month. If your account doesn't have enough credits, the API call will be reverted and you'll receive an error message. If you want to store the data for longer than one month, you'll need to use Temporal's HTTP API, and invoke the `extend pin` API call to extend the pin duration.

Any calls that involve "retrieving data" aren't rate limited and you're free to use them as you please. To increase performance, data retrieval calls go through a caching system. If you want to skip the caching system receive uncached responses, set the `Cache-Control` header to `"no-store"`.

## Example

Expand All @@ -24,7 +35,7 @@ import (
)

const (
temporalReverseProxy = "https://dev.api.ipfs.temporal.cloud"
temporalReverseProxy = "https://api.ipfs.temporal.cloud"
exampleCID = "QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv"
)

Expand Down Expand Up @@ -71,14 +82,14 @@ Python code here.

```shell
curl -X POST \
'https://dev.api.ipfs.temporal.cloud/api/v0/pin/add?arg=QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv&stream-channels=true' \
'https://api.ipfs.temporal.cloud/api/v0/pin/add?arg=QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv&stream-channels=true' \
-H 'Authorization: Bearer <your-jwt-here>' \
-H 'cache-control: no-cache'
```

```http
POST /api/v0/pin/add?arg=QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv&stream-channels=true HTTP/1.1
Host: dev.api.ipfs.temporal.cloud
Host: api.ipfs.temporal.cloud
User-Agent: curl/7.58.0
Accept: */*
Authorization: Bearer <jwt-omitted>
Expand All @@ -98,7 +109,7 @@ var jwt = process.env.TEMPORAL_JWT
// specify how we will connect the ipfs client
var ipfs = ipfsClient({
// the hostname (or ip address) of the endpoint providing the ipfs api
host: 'dev.api.ipfs.temporal.cloud',
host: 'api.ipfs.temporal.cloud',
// the port to connect on
port: '443',
'api-path': '/api/v0/',
Expand Down

0 comments on commit 1e509c2

Please sign in to comment.