✨
Singularity
English
English
  • Overview
    • What is Singularity
    • V1 or V2
  • Installation
    • Download binaries
    • Install via docker
    • Built from source
    • Deploy to production
    • Version upgrade
  • Data Preparation
    • Get Started
    • Performance Tuning
  • Content Distribution
    • Distribute CAR files
  • Deal Making
    • Create a deal schedule
  • Topics
    • Inline Preparation
    • Benchmark
  • 💻CLI Reference
    • Menu
    • Ez Prep
    • Version
    • Admin
      • Init
      • Reset
      • Migrate Dataset
      • Migrate Schedule
    • Download
    • Extract Car
    • Deal
      • Schedule
        • Create
        • List
        • Update
        • Pause
        • Resume
        • Remove
      • Send Manual
      • List
    • Run
      • Api
      • Dataset Worker
      • Content Provider
      • Deal Tracker
      • Deal Pusher
      • Download Server
    • Wallet
      • Import
      • List
      • Remove
    • Storage
      • Create
        • Acd
        • Azureblob
        • B2
        • Box
        • Drive
        • Dropbox
        • Fichier
        • Filefabric
        • Ftp
        • Google Cloud Storage
        • Gphotos
        • Hdfs
        • Hidrive
        • Http
        • Internetarchive
        • Jottacloud
        • Koofr / Digi Storage
          • Digistorage
          • Koofr / Digi Storage
          • Other
        • Local
        • Mailru
        • Mega
        • Netstorage
        • Onedrive
        • Oos
          • Env_auth
          • Instance_principal_auth
          • No_auth
          • Resource_principal_auth
          • User_principal_auth
        • Opendrive
        • Pcloud
        • Premiumizeme
        • Putio
        • Qingstor
        • AWS S3 and compliant
          • Aws
          • Alibaba
          • Arvancloud
          • Ceph
          • Chinamobile
          • Cloudflare
          • Digitalocean
          • Dreamhost
          • Huaweiobs
          • Ibmcos
          • Idrive
          • Ionos
          • Liara
          • Lyvecloud
          • Minio
          • Netease
          • Other
          • Qiniu
          • Rackcorp
          • Scaleway
          • Seaweedfs
          • Stackpath
          • Storj
          • Tencentcos
          • Wasabi
        • Seafile
        • Sftp
        • Sharefile
        • Sia
        • Smb
        • Storj
          • Existing
          • New
        • Sugarsync
        • Swift
        • Union
        • Uptobox
        • Webdav
        • Yandex
        • Zoho
      • Explore
      • List
      • Remove
      • Update
        • Acd
        • Azureblob
        • B2
        • Box
        • Drive
        • Dropbox
        • Fichier
        • Filefabric
        • Ftp
        • Google Cloud Storage
        • Gphotos
        • Hdfs
        • Hidrive
        • Http
        • Internetarchive
        • Jottacloud
        • Koofr / Digi Storage
          • Digistorage
          • Koofr / Digi Storage
          • Other
        • Local
        • Mailru
        • Mega
        • Netstorage
        • Onedrive
        • Oos
          • Env_auth
          • Instance_principal_auth
          • No_auth
          • Resource_principal_auth
          • User_principal_auth
        • Opendrive
        • Pcloud
        • Premiumizeme
        • Putio
        • Qingstor
        • AWS S3 and compliant
          • Aws
          • Alibaba
          • Arvancloud
          • Ceph
          • Chinamobile
          • Cloudflare
          • Digitalocean
          • Dreamhost
          • Huaweiobs
          • Ibmcos
          • Idrive
          • Ionos
          • Liara
          • Lyvecloud
          • Minio
          • Netease
          • Other
          • Qiniu
          • Rackcorp
          • Scaleway
          • Seaweedfs
          • Stackpath
          • Storj
          • Tencentcos
          • Wasabi
        • Seafile
        • Sftp
        • Sharefile
        • Sia
        • Smb
        • Storj
          • Existing
          • New
        • Sugarsync
        • Swift
        • Union
        • Uptobox
        • Webdav
        • Yandex
        • Zoho
      • Rename
    • Prep
      • Create
      • List
      • Status
      • Rename
      • Attach Source
      • Attach Output
      • Detach Output
      • Start Scan
      • Pause Scan
      • Start Pack
      • Pause Pack
      • Start Daggen
      • Pause Daggen
      • List Pieces
      • Add Piece
      • Explore
      • Attach Wallet
      • List Wallets
      • Detach Wallet
      • Remove
  • 🌐Web API Reference
    • Admin
    • Deal Schedule
    • Deal
    • File
    • Job
    • Piece
    • Preparation
    • Storage
    • Wallet Association
    • Wallet
    • Specification
  • ❓FAQ
    • Database is locked
Powered by GitBook
On this page

Was this helpful?

Edit on GitHub
  1. Web API Reference

Deal Schedule

PreviousAdminNextDeal

Last updated 1 year ago

Was this helpful?

🌐

List all schedules for a preparation

get
Path parameters
idstringRequired

Preparation ID or name

Responses
200
OK
application/json
400
Bad Request
application/json
500
Internal Server Error
application/json
get
GET /api/preparation/{id}/schedules HTTP/1.1
Host: localhost:9090
Accept: */*
[
  {
    "allowedPieceCids": [
      "text"
    ],
    "announceToIpni": true,
    "createdAt": "text",
    "duration": 1,
    "errorMessage": "text",
    "force": true,
    "httpHeaders": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "id": 1,
    "keepUnsealed": true,
    "maxPendingDealNumber": 1,
    "maxPendingDealSize": 1,
    "notes": "text",
    "preparationId": 1,
    "pricePerDeal": 1,
    "pricePerGb": 1,
    "pricePerGbEpoch": 1,
    "provider": "text",
    "scheduleCron": "text",
    "scheduleCronPerpetual": true,
    "scheduleDealNumber": 1,
    "scheduleDealSize": 1,
    "startDelay": 1,
    "state": "active",
    "totalDealNumber": 1,
    "totalDealSize": 1,
    "updatedAt": "text",
    "urlTemplate": "text",
    "verified": true
  }
]

List all deal making schedules

get
Responses
200
OK
application/json
400
Bad Request
application/json
500
Internal Server Error
application/json
get
GET /api/schedule HTTP/1.1
Host: localhost:9090
Accept: */*
[
  {
    "allowedPieceCids": [
      "text"
    ],
    "announceToIpni": true,
    "createdAt": "text",
    "duration": 1,
    "errorMessage": "text",
    "force": true,
    "httpHeaders": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "id": 1,
    "keepUnsealed": true,
    "maxPendingDealNumber": 1,
    "maxPendingDealSize": 1,
    "notes": "text",
    "preparationId": 1,
    "pricePerDeal": 1,
    "pricePerGb": 1,
    "pricePerGbEpoch": 1,
    "provider": "text",
    "scheduleCron": "text",
    "scheduleCronPerpetual": true,
    "scheduleDealNumber": 1,
    "scheduleDealSize": 1,
    "startDelay": 1,
    "state": "active",
    "totalDealNumber": 1,
    "totalDealSize": 1,
    "updatedAt": "text",
    "urlTemplate": "text",
    "verified": true
  }
]

Delete a specific schedule

delete
Path parameters
idintegerRequired

Schedule ID

Responses
204
No Content
400
Bad Request
application/json
500
Internal Server Error
application/json
delete
DELETE /api/schedule/{id} HTTP/1.1
Host: localhost:9090
Accept: */*

No content

Pause a specific schedule

post
Path parameters
idintegerRequired

Schedule ID

Responses
200
OK
application/json
400
Bad Request
application/json
500
Internal Server Error
application/json
post
POST /api/schedule/{id}/pause HTTP/1.1
Host: localhost:9090
Accept: */*
{
  "allowedPieceCids": [
    "text"
  ],
  "announceToIpni": true,
  "createdAt": "text",
  "duration": 1,
  "errorMessage": "text",
  "force": true,
  "httpHeaders": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "id": 1,
  "keepUnsealed": true,
  "maxPendingDealNumber": 1,
  "maxPendingDealSize": 1,
  "notes": "text",
  "preparationId": 1,
  "pricePerDeal": 1,
  "pricePerGb": 1,
  "pricePerGbEpoch": 1,
  "provider": "text",
  "scheduleCron": "text",
  "scheduleCronPerpetual": true,
  "scheduleDealNumber": 1,
  "scheduleDealSize": 1,
  "startDelay": 1,
  "state": "active",
  "totalDealNumber": 1,
  "totalDealSize": 1,
  "updatedAt": "text",
  "urlTemplate": "text",
  "verified": true
}

Resume a specific schedule

post
Path parameters
idintegerRequired

Schedule ID

Responses
200
OK
application/json
400
Bad Request
application/json
500
Internal Server Error
application/json
post
POST /api/schedule/{id}/resume HTTP/1.1
Host: localhost:9090
Accept: */*
{
  "allowedPieceCids": [
    "text"
  ],
  "announceToIpni": true,
  "createdAt": "text",
  "duration": 1,
  "errorMessage": "text",
  "force": true,
  "httpHeaders": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "id": 1,
  "keepUnsealed": true,
  "maxPendingDealNumber": 1,
  "maxPendingDealSize": 1,
  "notes": "text",
  "preparationId": 1,
  "pricePerDeal": 1,
  "pricePerGb": 1,
  "pricePerGbEpoch": 1,
  "provider": "text",
  "scheduleCron": "text",
  "scheduleCronPerpetual": true,
  "scheduleDealNumber": 1,
  "scheduleDealSize": 1,
  "startDelay": 1,
  "state": "active",
  "totalDealNumber": 1,
  "totalDealSize": 1,
  "updatedAt": "text",
  "urlTemplate": "text",
  "verified": true
}
  • GETList all schedules for a preparation
  • GETList all deal making schedules
  • POSTCreate a new schedule
  • DELETEDelete a specific schedule
  • PATCHUpdate a schedule
  • POSTPause a specific schedule
  • POSTResume a specific schedule

Create a new schedule

post

Create a new schedule

Body
allowedPieceCidsstring[]Optional

Allowed piece CIDs in this schedule

durationstringOptional

Duration in epoch or in duration format, i.e. 1500000, 2400h

Default: 12840h
forcebooleanOptional

Force to send out deals regardless of replication restriction

httpHeadersstring[]Optional

http headers to be passed with the request (i.e. key=value)

ipnibooleanOptional

Whether the deal should be IPNI

Default: true
keepUnsealedbooleanOptional

Whether the deal should be kept unsealed

Default: true
maxPendingDealNumberintegerOptional

Max pending deal number

maxPendingDealSizestringOptional

Max pending deal size in human readable format, i.e. 100 TiB

notesstringOptional

Notes

preparationstringOptional

Preparation ID or name

pricePerDealnumberOptional

Price in FIL per deal

Default: 0
pricePerGbnumberOptional

Price in FIL per GiB

Default: 0
pricePerGbEpochnumberOptional

Price in FIL per GiB per epoch

Default: 0
providerstringOptional

Provider

scheduleCronstringOptional

Schedule cron pattern

scheduleCronPerpetualbooleanOptional

Whether a cron schedule should run in definitely

scheduleDealNumberintegerOptional

Number of deals per scheduled time

scheduleDealSizestringOptional

Size of deals per schedule trigger in human readable format, i.e. 100 TiB

startDelaystringOptional

Deal start delay in epoch or in duration format, i.e. 1000, 72h

Default: 72h
totalDealNumberintegerOptional

Total number of deals

totalDealSizestringOptional

Total size of deals in human readable format, i.e. 100 TiB

urlTemplatestringOptional

URL template with PIECE_CID placeholder for boost to fetch the CAR file, i.e. http://127.0.0.1/piece/{PIECE_CID}.car

verifiedbooleanOptional

Whether the deal should be verified

Default: true
Responses
200
OK
application/json
400
Bad Request
application/json
500
Internal Server Error
application/json
post
POST /api/schedule HTTP/1.1
Host: localhost:9090
Content-Type: application/json
Accept: */*
Content-Length: 474

{
  "allowedPieceCids": [
    "text"
  ],
  "duration": "text",
  "force": true,
  "httpHeaders": [
    "text"
  ],
  "ipni": true,
  "keepUnsealed": true,
  "maxPendingDealNumber": 1,
  "maxPendingDealSize": "text",
  "notes": "text",
  "preparation": "text",
  "pricePerDeal": 1,
  "pricePerGb": 1,
  "pricePerGbEpoch": 1,
  "provider": "text",
  "scheduleCron": "text",
  "scheduleCronPerpetual": true,
  "scheduleDealNumber": 1,
  "scheduleDealSize": "text",
  "startDelay": "text",
  "totalDealNumber": 1,
  "totalDealSize": "text",
  "urlTemplate": "text",
  "verified": true
}
{
  "allowedPieceCids": [
    "text"
  ],
  "announceToIpni": true,
  "createdAt": "text",
  "duration": 1,
  "errorMessage": "text",
  "force": true,
  "httpHeaders": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "id": 1,
  "keepUnsealed": true,
  "maxPendingDealNumber": 1,
  "maxPendingDealSize": 1,
  "notes": "text",
  "preparationId": 1,
  "pricePerDeal": 1,
  "pricePerGb": 1,
  "pricePerGbEpoch": 1,
  "provider": "text",
  "scheduleCron": "text",
  "scheduleCronPerpetual": true,
  "scheduleDealNumber": 1,
  "scheduleDealSize": 1,
  "startDelay": 1,
  "state": "active",
  "totalDealNumber": 1,
  "totalDealSize": 1,
  "updatedAt": "text",
  "urlTemplate": "text",
  "verified": true
}

Update a schedule

patch

Update a schedule

Path parameters
idintegerRequired

Schedule ID

Body
allowedPieceCidsstring[]Optional

Allowed piece CIDs in this schedule

durationstringOptional

Duration in epoch or in duration format, i.e. 1500000, 2400h

Default: 12840h
forcebooleanOptional

Force to send out deals regardless of replication restriction

httpHeadersstring[]Optional

http headers to be passed with the request (i.e. key=value)

ipnibooleanOptional

Whether the deal should be IPNI

Default: true
keepUnsealedbooleanOptional

Whether the deal should be kept unsealed

Default: true
maxPendingDealNumberintegerOptional

Max pending deal number

maxPendingDealSizestringOptional

Max pending deal size in human readable format, i.e. 100 TiB

notesstringOptional

Notes

pricePerDealnumberOptional

Price in FIL per deal

Default: 0
pricePerGbnumberOptional

Price in FIL per GiB

Default: 0
pricePerGbEpochnumberOptional

Price in FIL per GiB per epoch

Default: 0
scheduleCronstringOptional

Schedule cron pattern

scheduleCronPerpetualbooleanOptional

Whether a cron schedule should run in definitely

scheduleDealNumberintegerOptional

Number of deals per scheduled time

scheduleDealSizestringOptional

Size of deals per schedule trigger in human readable format, i.e. 100 TiB

startDelaystringOptional

Deal start delay in epoch or in duration format, i.e. 1000, 72h

Default: 72h
totalDealNumberintegerOptional

Total number of deals

totalDealSizestringOptional

Total size of deals in human readable format, i.e. 100 TiB

urlTemplatestringOptional

URL template with PIECE_CID placeholder for boost to fetch the CAR file, i.e. http://127.0.0.1/piece/{PIECE_CID}.car

verifiedbooleanOptional

Whether the deal should be verified

Default: true
Responses
200
OK
application/json
400
Bad Request
application/json
500
Internal Server Error
application/json
patch
PATCH /api/schedule/{id} HTTP/1.1
Host: localhost:9090
Content-Type: application/json
Accept: */*
Content-Length: 435

{
  "allowedPieceCids": [
    "text"
  ],
  "duration": "text",
  "force": true,
  "httpHeaders": [
    "text"
  ],
  "ipni": true,
  "keepUnsealed": true,
  "maxPendingDealNumber": 1,
  "maxPendingDealSize": "text",
  "notes": "text",
  "pricePerDeal": 1,
  "pricePerGb": 1,
  "pricePerGbEpoch": 1,
  "scheduleCron": "text",
  "scheduleCronPerpetual": true,
  "scheduleDealNumber": 1,
  "scheduleDealSize": "text",
  "startDelay": "text",
  "totalDealNumber": 1,
  "totalDealSize": "text",
  "urlTemplate": "text",
  "verified": true
}
{
  "allowedPieceCids": [
    "text"
  ],
  "announceToIpni": true,
  "createdAt": "text",
  "duration": 1,
  "errorMessage": "text",
  "force": true,
  "httpHeaders": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "id": 1,
  "keepUnsealed": true,
  "maxPendingDealNumber": 1,
  "maxPendingDealSize": 1,
  "notes": "text",
  "preparationId": 1,
  "pricePerDeal": 1,
  "pricePerGb": 1,
  "pricePerGbEpoch": 1,
  "provider": "text",
  "scheduleCron": "text",
  "scheduleCronPerpetual": true,
  "scheduleDealNumber": 1,
  "scheduleDealSize": 1,
  "startDelay": 1,
  "state": "active",
  "totalDealNumber": 1,
  "totalDealSize": 1,
  "updatedAt": "text",
  "urlTemplate": "text",
  "verified": true
}