title: Google Cloud Adding a user to a project
body: <p>I want to be able to programatically add a user to a project that exists in google cloud. I can do this via the console by going to Iam and admin, selecting a project, then searching for a user, selecting a role and adding them. Furthermore, the <a href="https://cloud.google.com/iam/docs/granting-changing-revoking-access" rel="nofollow noreferrer">docs</a> seem to say this should be possible</p>
  
  <blockquote>
    <p>Project owners can grant access to team members to access project's
    resources and APIs by granting IAM roles to team members. You can
    grant a role to a team member using the Cloud Platform Console, the
    cloud command-line tool, or the setIamPolicy() method.</p>
  </blockquote>
  
  <p>But the API <a href="https://cloud.google.com/resource-manager/reference/rest/v1/projects" rel="nofollow noreferrer">seems</a> to be missing this method.</p>
  
  <p>I can grant users access to particular resources, but I cant give them the same kind of <em>all resource</em> access level that I can from the console.</p>
  
  <p>What API call can I use to, say, grant a given user read-only access to all the resources in a given project?</p>