Files
probo/pkg/server/api/console/v1/graphql/organization.graphql
Cursor Agent 8b6e9e420a Allow ordering profiles by email address
GraphQL profile ordering rejected EMAIL_ADDRESS because ProfileOrderField
did not expose this enum value in connect and console schemas.

Add EMAIL_ADDRESS to MembershipProfileOrderField and its validation list
so order input coercion accepts the value consistently. Extend
MembershipProfile cursor key encoding to support email ordering and avoid
runtime panics during pagination.

Update the MCP profile order enum to keep API surface definitions aligned
with the same ordering capability.

Signed-off-by: Cursor Agent <cursoragent@cursor.com>

Co-authored-by: Bryan FRIMIN <bryan@frimin.fr>
2026-05-28 12:23:17 -07:00

362 lines
9.5 KiB
GraphQL

type OrganizationContext {
organizationId: ID!
product: String
architecture: String
team: String
processes: String
customers: String
}
enum ProfileState
@goModel(model: "go.probo.inc/probo/pkg/coredata.ProfileState") {
ACTIVE @goEnum(value: "go.probo.inc/probo/pkg/coredata.ProfileStateActive")
INACTIVE
@goEnum(value: "go.probo.inc/probo/pkg/coredata.ProfileStateInactive")
}
type Profile implements Node {
id: ID!
fullName: String!
emailAddress: EmailAddr!
state: ProfileState!
additionalEmailAddresses: [EmailAddr!]!
kind: String
position: String
contractStartDate: Datetime
contractEndDate: Datetime
createdAt: Datetime!
updatedAt: Datetime!
permission(action: String!): Boolean! @goField(forceResolver: true)
}
enum ProfileOrderField
@goModel(model: "go.probo.inc/probo/pkg/coredata.MembershipProfileOrderField") {
FULL_NAME
@goEnum(
value: "go.probo.inc/probo/pkg/coredata.MembershipProfileOrderFieldFullName"
)
CREATED_AT
@goEnum(
value: "go.probo.inc/probo/pkg/coredata.MembershipProfileOrderFieldCreatedAt"
)
EMAIL_ADDRESS
@goEnum(
value: "go.probo.inc/probo/pkg/coredata.MembershipProfileOrderFieldEmailAddress"
)
KIND @goEnum(value: "go.probo.inc/probo/pkg/coredata.MembershipProfileOrderFieldKind")
}
input ProfileOrder
@goModel(
model: "go.probo.inc/probo/pkg/server/api/console/v1/types.ProfileOrderBy"
) {
direction: OrderDirection!
field: ProfileOrderField!
}
input ProfileFilter {
contractEnded: Boolean
state: ProfileState
}
type ProfileConnection
@goModel(
model: "go.probo.inc/probo/pkg/server/api/console/v1/types.ProfileConnection"
) {
totalCount: Int! @goField(forceResolver: true)
edges: [ProfileEdge!]!
pageInfo: PageInfo!
}
type ProfileEdge {
cursor: CursorKey!
node: Profile!
}
input UpdateOrganizationContextInput {
organizationId: ID!
product: String @goField(omittable: true)
architecture: String @goField(omittable: true)
team: String @goField(omittable: true)
processes: String @goField(omittable: true)
customers: String @goField(omittable: true)
}
type UpdateOrganizationContextPayload {
context: OrganizationContext!
}
type Organization implements Node {
id: ID!
name: String!
logoUrl: String @goField(forceResolver: true)
horizontalLogoUrl: String @goField(forceResolver: true)
description: String
websiteUrl: String
email: String
headquarterAddress: String
context: OrganizationContext @goField(forceResolver: true)
profiles(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: ProfileOrder
filter: ProfileFilter
): ProfileConnection! @goField(forceResolver: true)
measureCategories: [String!]! @goField(forceResolver: true)
accessSources(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: AccessSourceOrder
): AccessSourceConnection! @goField(forceResolver: true)
accessReviewCampaigns(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: AccessReviewCampaignOrder
): AccessReviewCampaignConnection! @goField(forceResolver: true)
assetListDocument: Document @goField(forceResolver: true)
assets(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: AssetOrder
): AssetConnection! @goField(forceResolver: true)
dataListDocument: Document @goField(forceResolver: true)
data(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: DatumOrder
): DatumConnection! @goField(forceResolver: true)
audits(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: AuditOrder
): AuditConnection! @goField(forceResolver: true)
findingsDocument: Document @goField(forceResolver: true)
findings(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: FindingOrder
filter: FindingFilter
): FindingConnection @goField(forceResolver: true)
auditLogEntries(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: AuditLogEntryOrder
filter: AuditLogEntryFilter
): AuditLogEntryConnection! @goField(forceResolver: true)
slackConnections(
first: Int
after: CursorKey
last: Int
before: CursorKey
): SlackConnectionConnection! @goField(forceResolver: true)
slackOAuth2Scopes: [String!]! @goField(forceResolver: true)
connectors(filter: ConnectorFilter): [Connector!]! @goField(forceResolver: true)
connectorProviderInfos: [ConnectorProviderInfo!]! @goField(forceResolver: true)
controls(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: ControlOrder
filter: ControlFilter
): ControlConnection! @goField(forceResolver: true)
statementsOfApplicability(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: StatementOfApplicabilityOrder
): StatementOfApplicabilityConnection! @goField(forceResolver: true)
dataProtectionImpactAssessments(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: DataProtectionImpactAssessmentOrder
): DataProtectionImpactAssessmentConnection! @goField(forceResolver: true)
dataProtectionImpactAssessmentsDocument: Document
@goField(forceResolver: true)
transferImpactAssessments(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: TransferImpactAssessmentOrder
): TransferImpactAssessmentConnection! @goField(forceResolver: true)
transferImpactAssessmentsDocument: Document @goField(forceResolver: true)
documents(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: DocumentOrder
filter: DocumentFilter
): DocumentConnection! @goField(forceResolver: true)
frameworks(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: FrameworkOrder
): FrameworkConnection! @goField(forceResolver: true)
measures(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: MeasureOrder
filter: MeasureFilter
): MeasureConnection! @goField(forceResolver: true)
obligationsDocument: Document @goField(forceResolver: true)
obligations(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: ObligationOrder
): ObligationConnection! @goField(forceResolver: true)
processingActivities(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: ProcessingActivityOrder
): ProcessingActivityConnection! @goField(forceResolver: true)
processingActivitiesDocument: Document @goField(forceResolver: true)
rightsRequests(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: RightsRequestOrder
): RightsRequestConnection! @goField(forceResolver: true)
risks(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: RiskOrder
filter: RiskFilter
): RiskConnection! @goField(forceResolver: true)
risksDocument: Document @goField(forceResolver: true)
riskAssessments(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: RiskAssessmentOrder
): RiskAssessmentConnection! @goField(forceResolver: true)
riskAssessmentScenarios(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: RiskAssessmentScenarioOrder
): RiskAssessmentScenarioConnection @goField(forceResolver: true)
tasks(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: TaskOrder
): TaskConnection! @goField(forceResolver: true)
trustCenter: TrustCenter @goField(forceResolver: true)
customDomain: CustomDomain @goField(forceResolver: true)
trustCenterFiles(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: TrustCenterFileOrder
): TrustCenterFileConnection! @goField(forceResolver: true)
cookieBanners(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: CookieBannerOrder
): CookieBannerConnection @goField(forceResolver: true)
thirdParties(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: ThirdPartyOrder
filter: ThirdPartyFilter
): ThirdPartyConnection! @goField(forceResolver: true)
thirdPartiesDocument: Document @goField(forceResolver: true)
webhookSubscriptions(
first: Int
after: CursorKey
last: Int
before: CursorKey
orderBy: WebhookSubscriptionOrder
): WebhookSubscriptionConnection! @goField(forceResolver: true)
createdAt: Datetime!
updatedAt: Datetime!
permission(action: String!): Boolean! @goField(forceResolver: true)
}
extend type Mutation {
updateOrganizationContext(
input: UpdateOrganizationContextInput!
): UpdateOrganizationContextPayload!
}