github.com/gophercloud/gophercloud@v1.11.0/openstack/identity/v3/extensions/oauth1/urls.go (about)

     1  package oauth1
     2  
     3  import "github.com/gophercloud/gophercloud"
     4  
     5  func consumersURL(c *gophercloud.ServiceClient) string {
     6  	return c.ServiceURL("OS-OAUTH1", "consumers")
     7  }
     8  
     9  func consumerURL(c *gophercloud.ServiceClient, id string) string {
    10  	return c.ServiceURL("OS-OAUTH1", "consumers", id)
    11  }
    12  
    13  func requestTokenURL(c *gophercloud.ServiceClient) string {
    14  	return c.ServiceURL("OS-OAUTH1", "request_token")
    15  }
    16  
    17  func authorizeTokenURL(c *gophercloud.ServiceClient, id string) string {
    18  	return c.ServiceURL("OS-OAUTH1", "authorize", id)
    19  }
    20  
    21  func createAccessTokenURL(c *gophercloud.ServiceClient) string {
    22  	return c.ServiceURL("OS-OAUTH1", "access_token")
    23  }
    24  
    25  func userAccessTokensURL(c *gophercloud.ServiceClient, userID string) string {
    26  	return c.ServiceURL("users", userID, "OS-OAUTH1", "access_tokens")
    27  }
    28  
    29  func userAccessTokenURL(c *gophercloud.ServiceClient, userID string, id string) string {
    30  	return c.ServiceURL("users", userID, "OS-OAUTH1", "access_tokens", id)
    31  }
    32  
    33  func userAccessTokenRolesURL(c *gophercloud.ServiceClient, userID string, id string) string {
    34  	return c.ServiceURL("users", userID, "OS-OAUTH1", "access_tokens", id, "roles")
    35  }
    36  
    37  func userAccessTokenRoleURL(c *gophercloud.ServiceClient, userID string, id string, roleID string) string {
    38  	return c.ServiceURL("users", userID, "OS-OAUTH1", "access_tokens", id, "roles", roleID)
    39  }
    40  
    41  func authURL(c *gophercloud.ServiceClient) string {
    42  	return c.ServiceURL("auth", "tokens")
    43  }