Sha256: 1094db17e71d9584950b567f1277a37fea8e1a0d56e9a4beab7b35756cba354b

Contents?: true

Size: 1.01 KB

Versions: 22

Compression:

Stored size: 1.01 KB

Contents

This sample demonstrates how to manage user accounts.

$ cc -lcouchbase users.c

$ ./a.out couchbase://192.168.1.194 Administrator password
1. Create account 'cbtestuser' with predefined set of roles
HTTP status: 200
Server: Couchbase Server
Pragma: no-cache
Date: Fri, 23 Jun 2017 12:39:52 GMT
Content-Type: application/json
Content-Length: 2
Cache-Control: no-cache
""
2. Retrieve list of all accounts in the cluster
HTTP status: 200
Transfer-Encoding: chunked
Server: Couchbase Server
Pragma: no-cache
Date: Fri, 23 Jun 2017 12:39:52 GMT
Content-Type: application/json
Cache-Control: no-cache
[
  {
    "name": "TestUser",
    "id": "cbtestuser",
    "domain": "local",
    "roles": [
      {
        "role": "bucket_admin",
        "bucket_name": "default"
      },
      {
        "role": "cluster_admin"
      }
    ]
  }
]

3. Remove account 'cbtestuser'
HTTP status: 200
Server: Couchbase Server
Pragma: no-cache
Date: Fri, 23 Jun 2017 12:39:52 GMT
Content-Type: application/json
Content-Length: 2
Cache-Control: no-cache
""

Version data entries

22 entries across 22 versions & 2 rubygems

Version Path
mt-libcouchbase-1.4.03 ext/libcouchbase/example/users/README
mt-libcouchbase-1.4.02 ext/libcouchbase/example/users/README
mt-libcouchbase-1.4.01 ext/libcouchbase/example/users/README
mt-libcouchbase-1.4.0 ext/libcouchbase/example/users/README
libcouchbase-1.3.2 ext/libcouchbase/example/users/README
libcouchbase-1.3.0 ext/libcouchbase/example/users/README
libcouchbase-1.2.8 ext/libcouchbase/example/users/README
libcouchbase-1.2.7 ext/libcouchbase/example/users/README
libcouchbase-1.2.6 ext/libcouchbase/example/users/README
libcouchbase-1.2.5 ext/libcouchbase/example/users/README
libcouchbase-1.2.4 ext/libcouchbase/example/users/README
libcouchbase-1.2.3 ext/libcouchbase/example/users/README
libcouchbase-1.2.2 ext/libcouchbase/example/users/README
libcouchbase-1.2.1 ext/libcouchbase/example/users/README
libcouchbase-1.2.0 ext/libcouchbase/example/users/README
libcouchbase-1.1.1 ext/libcouchbase/example/users/README
libcouchbase-1.1.0 ext/libcouchbase/example/users/README
libcouchbase-1.0.4 ext/libcouchbase/example/users/README
libcouchbase-1.0.3 ext/libcouchbase/example/users/README
libcouchbase-1.0.2 ext/libcouchbase/example/users/README