Skip to content

Commit be1e2c8

Browse files
committed
GQL-16: Renames to Group, adds members sub query, change userGroupIdOrName to id
1 parent a9ed085 commit be1e2c8

File tree

19 files changed

+995
-609
lines changed

19 files changed

+995
-609
lines changed

README.md

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ Currently, this API supports the following functionality within NASA's Earthdata
189189
- [Services](#services)
190190
- [Subscriptions](#subscriptions)
191191
- [Tools](#tools)
192-
- [User Groups](#user-groups)
192+
- [Groups](#groups)
193193
- [Variables](#variables)
194194

195195
### Drafts of concepts
@@ -603,7 +603,7 @@ Variables:
603603
###### Restore a previous revision of a tool
604604

605605
```gql
606-
mutation RestoreToolnRevision(
606+
mutation RestoreToolRevision(
607607
$conceptId: String!
608608
$revisionId: String!
609609
) {
@@ -617,20 +617,20 @@ mutation RestoreToolnRevision(
617617
}
618618
```
619619

620-
#### User Groups
620+
#### Groups
621621

622-
For all supported arguments and columns, see [the schema](src/types/userGroup.graphql).
622+
For all supported arguments and columns, see [the schema](src/types/group.graphql).
623623

624-
##### User Group Queries
624+
##### Group Queries
625625

626-
###### Query for a single user group
626+
###### Query for a single group
627627

628628
Query:
629629
```gql
630-
query UserGroup (
631-
$params: UserGroupInput
630+
query Group (
631+
$params: GroupInput
632632
) {
633-
userGroup (
633+
group (
634634
params: $params
635635
) {
636636
groupId
@@ -648,14 +648,14 @@ Variables:
648648
}
649649
```
650650

651-
###### Query for multiple user groups
651+
###### Query for multiple groups
652652

653653
Query:
654654
```gql
655-
query UserGroups (
656-
$params: UserGroupsInput
655+
query Groups (
656+
$params: GroupsInput
657657
) {
658-
userGroups (
658+
groups (
659659
params: $params
660660
) {
661661
count
@@ -672,23 +672,23 @@ Variables:
672672
{
673673
"params": {
674674
"tags": ["EXAMPLE"],
675-
"name": "user-group-1"
675+
"name": "group-1"
676676
}
677677
}
678678
```
679679

680-
##### User Group Mutations
680+
##### Group Mutations
681681

682-
###### Creating a user group
682+
###### Creating a group
683683

684684
Query:
685685
```gql
686-
mutation CreateUserGroup (
686+
mutation CreateGroup (
687687
$name: String!
688688
$tag: String
689689
$description: String
690690
) {
691-
createUserGroup (
691+
createGroup (
692692
name: $name
693693
tag: $tag
694694
description: $description
@@ -708,16 +708,16 @@ Variables:
708708
}
709709
```
710710

711-
###### Updating a user group
711+
###### Updating a group
712712

713713
Query:
714714
```gql
715-
mutation UpdateUserGroup (
716-
$userGroupIdOrName: String!
715+
mutation UpdateGroup (
716+
$id: String!
717717
$name: String
718718
) {
719-
updateUserGroup (
720-
userGroupIdOrName: $userGroupIdOrName
719+
updateGroup (
720+
id: $id
721721
name: $name
722722
) {
723723
groupId
@@ -729,19 +729,19 @@ mutation UpdateUserGroup (
729729
Variables:
730730
```json
731731
{
732-
"userGroupIdOrName": "1234-abcd-5678-efgh",
732+
"id": "1234-abcd-5678-efgh",
733733
"name": "New Group Name"
734734
}
735735
```
736736

737-
###### Deleting a user group
737+
###### Deleting a group
738738

739739
Query:
740740
```gql
741-
mutation DeleteUserGroup (
741+
mutation DeleteGroup (
742742
$id: String!
743743
) {
744-
deleteUserGroup (
744+
deleteGroup (
745745
id: $id
746746
)
747747
}
@@ -1100,7 +1100,7 @@ For all supported arguments and columns, see [the schema](src/types/collection.g
11001100

11011101
CMR-GraphQL queries an earthdata-varinfo lambda in order to generate collection variable drafts. These generated variable drafts can be returned as part of the Collection type response.
11021102

1103-
`generateVariableDrafts` will return collection generated variable drafts, using the earthdata-varinfo project(<https://github.com/nasa/earthdata-varinfo>)
1103+
`generateVariableDrafts` will return collection generated variable drafts, using the earthdata-varinfo project(https://github.com/nasa/earthdata-varinfo)
11041104

11051105
##### Collection Variable Draft Queries
11061106

@@ -1180,7 +1180,7 @@ For all supported arguments and columns, see [the schema](src/types/variable.gra
11801180

11811181
CMR-GraphQL queries an earthdata-varinfo lambda in order to generate and publish collection variable drafts. The resulting variables can be returned as part of the Variable type response.
11821182

1183-
`publishVariableDrafts` will return collection generated variables, using the earthdata-varinfo project(<https://github.com/nasa/earthdata-varinfo>)
1183+
`publishVariableDrafts` will return collection generated variables, using the earthdata-varinfo project(https://github.com/nasa/earthdata-varinfo)
11841184

11851185
##### Generate Collection Variable Drafts Mutation
11861186

src/constants/index.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,15 @@ export const DRAFT_CONCEPT_ID_PREFIXES = {
3232
tool: 'TD',
3333
variable: 'VD'
3434
}
35+
36+
/**
37+
* Types of requests that can be send to EDL
38+
*/
39+
export const edlPathTypes = {
40+
CREATE_GROUP: 'CREATE_GROUP',
41+
DELETE_GROUP: 'DELETE_GROUP',
42+
FIND_GROUP: 'FIND_GROUP',
43+
FIND_MEMBERS: 'FIND_MEMBERS',
44+
SEARCH_GROUPS: 'SEARCH_GROUPS',
45+
UPDATE_GROUP: 'UPDATE_GROUP'
46+
}

0 commit comments

Comments
 (0)