colinskow / superlogin

Powerful authentication for APIs and single page apps using the CouchDB ecosystem which supports a variety of providers.
MIT License
371 stars 117 forks source link

Cloudant Not Adding Correct Permissions #132

Closed crowecawcaw closed 7 years ago

crowecawcaw commented 7 years ago

I have a simple webapp that's using superlogin for managing a Cloudant database. When I login, I can see on Cloudant that an API key has been added but the API key has no privileges. The relevant part of my config is below:

  userDBs: {
    defaultDBs: {
      private: ['sdb']
    }
  },
  model: {
    sdb: {
      permissions: ['_reader', '_writer', '_replicator', '_db_updates'],
      type: 'private'
    }
  }

Any tips for how to get the permissions corrected or what to check?

crowecawcaw commented 7 years ago

I just realized that the "model" object is supposed to be inside the "userDBs" object.