comparison mod_rest/README.markdown @ 4067:5790c3cf615b

mod_rest/README: Describe use on VirtualHosts
author Kim Alvefur <zash@zash.se>
date Mon, 20 Jul 2020 21:54:52 +0200
parents 2c6d5734ae04
children 504a0cd5f883
comparison
equal deleted inserted replaced
4066:07ae583bc565 4067:5790c3cf615b
10 Prosody. It can be used to build bots and components implemented as HTTP 10 Prosody. It can be used to build bots and components implemented as HTTP
11 services. 11 services.
12 12
13 # Usage 13 # Usage
14 14
15 ## Enabling 15 ## On VirtualHosts
16
17 ```lua
18 VirtualHost "example.com"
19 modules_enabled = {"rest"}
20 ```
21
22 ## As a Component
16 23
17 ``` {.lua} 24 ``` {.lua}
18 Component "rest.example.net" "rest" 25 Component "rest.example.net" "rest"
19 rest_credentials = "Bearer dmVyeSBzZWNyZXQgdG9rZW4K" 26 rest_credentials = "Bearer dmVyeSBzZWNyZXQgdG9rZW4K"
20 ``` 27 ```