Blockstream Enterprise
ReferenceAPI ReferenceRoles

Delete Roles

Delete Roles.

Request

RolesDeleteRequest
interface RolesDeleteRequest {
  action: 'delete'
  resource: string
  details?: {} | undefined
}

Prop

Type

Response

RolesDeleteResponse_success
interface RolesDeleteResponse_success {
  status: 'success'
  error_code?: '-1' | '-2' | '-3' | '-4' | '-5' | '-6' | '-7' | '-8' | '-9' | '-10' | '-11' | '-12' | '-13' | undefined
  message?: string | undefined
  details: {
    message: string
  }
  metadata: unknown
}

Prop

Type

RolesDeleteResponse_pending
interface RolesDeleteResponse_pending {
  status: 'pending'
  error_code?: '-1' | '-2' | '-3' | '-4' | '-5' | '-6' | '-7' | '-8' | '-9' | '-10' | '-11' | '-12' | '-13' | undefined
  message?: string | undefined
  details: {
    proposal_id: string
  }
}

Prop

Type

RolesDeleteResponse_failed | unauthorized | rejected
interface RolesDeleteResponse_failed | unauthorized | rejected {
  status: 'failed' | 'unauthorized' | 'rejected'
  error_code?: '-1' | '-2' | '-3' | '-4' | '-5' | '-6' | '-7' | '-8' | '-9' | '-10' | '-11' | '-12' | '-13' | undefined
  message?: string | undefined
}

Prop

Type

Example

Example
import { resourceSchema } from '@blockstream/ecs-js-sdk'
import { broadcastRequest } from './broadcaster'

const response = await broadcastRequest<
  typeof resourceSchema.shape.roles.shape.delete
>(
  {
    action: 'delete',
    resource: '/roles/{id}',
    details: {
      // TODO: fill in required fields
    },
  },
  blockstream,
)

On this page