WARNING: The [.Accept] file and the [accept-1] file type are deprecated, use the [.Buckets] file instead.

accept-1

Restrict what can be dropped on app instances.

Accepting means allowing a file to be dropped into an instance.

This accept-1 file type is only intended to be used on .Accept files.

Usage

An accept-1 file can be configured via string attributes named placeholder-N, where N is any valid placeholder: [0..255].

The attribute values must be a space separated lists of app methods. There are 2 special values:

  • .Image - currently only the built-in image-1 app implements it, and
  • .None - which can not be implemented.

Built-in methods you will likely want to use:

  • .Inline,
  • .Request,
  • .Page.

You can also use user-defined methods, like .foo. User defined methods start with a dot followed by a lower-case letter. This allows you to create applications that only allow one to drop specific file types - those that implement that interface.

Hidden placeholder 0

Note that placeholder 0 is a special placeholder in that it is treated as a hidden placeholder. This is the place where to store hidden files. Thus, it makes no sense to define accept rules for it, and it is recommended you do not define any.

Validating the .Accept file

Open it in your browser to validate it.

Examples

Accept nothing

{
    "title": "",
    "link": "",
    "type": "accept-1",
    "statusCode": 0,
    "attr": {}
}

Accept everything in placeholder 1

{
    "title": "",
    "link": "",
    "type": "accept-1",
    "statusCode": 0,
    "attr": {
        "placeholder-1 string": ""
    }
}

Accept pages only in placeholder 1

{
    "title": "",
    "link": "",
    "type": "accept-1",
    "statusCode": 0,
    "attr": {
        "placeholder-1 string": ".Page"
    }
}

Accept images only in placeholder 1

{
    "title": "",
    "link": "",
    "type": "accept-1",
    "statusCode": 0,
    "attr": {
        "placeholder-1 string": ".Image"
    }
}

Accept files only that can be inlined, in placeholder 1

{
    "title": "",
    "link": "",
    "type": "accept-1",
    "statusCode": 0,
    "attr": {
        "placeholder-1 string": ".Inline"
    }
}

Accept files that can be inlined or served as requests, in placeholder 1

{
    "title": "",
    "link": "",
    "type": "accept-1",
    "statusCode": 0,
    "attr": {
        "placeholder-1 string": ".Inline .Request"
    }
}

Accept files that can be inlined both in placeholder 1 and 2

{
    "title": "",
    "link": "",
    "type": "accept-1",
    "statusCode": 0,
    "attr": {
        "placeholder-1 string": ".Inline",
        "placeholder-2 string": ".Inline"
    }
}

Implemented OS Interfaces

.Request