mirror of
https://github.com/rclone/rclone.git
synced 2024-11-27 02:45:16 +01:00
1d14e30383
* added koofr client SDK dep for koofr backend
26 lines
436 B
Go
26 lines
436 B
Go
package koofrclient
|
|
|
|
import (
|
|
"net/http"
|
|
|
|
"github.com/koofr/go-httpclient"
|
|
)
|
|
|
|
func (c *KoofrClient) Shared() (shared []Shared, err error) {
|
|
d := &struct {
|
|
Files *[]Shared
|
|
}{&shared}
|
|
|
|
request := httpclient.RequestData{
|
|
Method: "GET",
|
|
Path: "/api/v2/shared",
|
|
ExpectedStatus: []int{http.StatusOK},
|
|
RespEncoding: httpclient.EncodingJSON,
|
|
RespValue: &d,
|
|
}
|
|
|
|
_, err = c.Request(&request)
|
|
|
|
return
|
|
}
|