Interface PermissionApi


  • public interface PermissionApi
    Provides access to SQS via their REST API.

    • Method Detail

      • addPermissionToAccount

        @Named("AddPermission")
        @POST
        @Path("/")
        void addPermissionToAccount​(@FormParam("Label")
                                    String label,
                                    @FormParam("ActionName.1")
                                    Action permission,
                                    @FormParam("AWSAccountId.1")
                                    String accountId)
        The AddPermission action adds a permission to a queue for a specific principal. This allows for sharing access to the queue. When you create a queue, you have full control access rights for the queue. Only you (as owner of the queue) can grant or deny permissions to the queue. For more information about these permissions, see Shared Queues in the Amazon SQS Developer Guide. Note AddPermission writes an SQS-generated policy. If you want to write your own policy, use SetQueueAttributes to upload your policy.
        Parameters:
        queue - queue to change permissions on
        label - The unique identification of the permission you're setting. example: AliceSendMessage Constraints: Maximum 80 characters; alphanumeric characters, hyphens (-), and underscores (_) are allowed.
        permission - The action you want to allow for the specified principal.
        accountId - The AWS account number of the principal who will be given permission. The principal must have an AWS account, but does not need to be signed up for Amazon SQS. For information about locating the AWS account identification, see Your AWS Identifiers in the Amazon SQS Developer Guide. Constraints: Valid 12-digit AWS account number, without hyphens
      • remove

        @Named("RemovePermission")
        @POST
        @Path("/")
        void remove​(@FormParam("Label")
                    String label)
        The RemovePermission action revokes any permissions in the queue policy that matches the Label parameter. Only the owner of the queue can remove permissions.
        Parameters:
        queue - queue to change permissions on
        label - The identification of the permission you want to remove. This is the label you added in AddPermission. example: AliceSendMessage