Class: Contentful::Management::PersonalAccessToken
- Inherits:
-
Object
- Object
- Contentful::Management::PersonalAccessToken
- Includes:
- Resource, Resource::Refresher, Resource::SystemProperties
- Defined in:
- lib/contentful/management/personal_access_token.rb
Overview
Resource class for PersonalAccessToken.
Instance Attribute Summary
Attributes included from Resource::SystemProperties
Attributes included from Resource
#client, #properties, #raw_object, #request
Instance Method Summary collapse
-
#destroy ⇒ Object
Not supported.
-
#revoke ⇒ Object
Revokes the personal access token.
Methods included from Resource::Refresher
Methods included from Resource
#array?, #default_locale, #environment_id, #fields, #nested_locale_fields?, #resource?, #save, #sys, #update
Instance Method Details
#destroy ⇒ Object
Not supported
33 34 35 |
# File 'lib/contentful/management/personal_access_token.rb', line 33 def destroy fail 'Not supported' end |
#revoke ⇒ Object
Revokes the personal access token.
38 39 40 41 42 43 44 |
# File 'lib/contentful/management/personal_access_token.rb', line 38 def revoke ResourceRequester.new(client, self.class).update( self, resource_id: id, suffix: '/revoked' ) end |