Newer
Older
"openapi": "3.0.2",
"info": {
"title": "Person API",
"version": "1.0.0",
"contact": {
"name": "DoIT Enterprise Integration API Team",
"email": "api@doit.wisc.edu",
"url": "https://go.wisc.edu/k701y6"
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
"description": "An API for interacting with person data at UW-Madison. Refer to the [Person API Documentation](/person-api) for more information about this API."
},
"servers": [
{
"url": "https://api.wisc.edu"
}
],
"security": [
{
"OAuth2ClientCredentials": []
}
],
"externalDocs": {
"description": "Read more about JSON:API here",
"url": "https://jsonapi.org/"
},
"paths": {
"/people": {
"get": {
"description": "Get a collection of people.",
"summary": "Get people.",
"operationId": "get_people",
"tags": [
"people"
],
"parameters": [
{
"name": "filter",
"in": "query",
"description": "Filter results of query using the [filter query parameter family](https://jsonapi.org/recommendations/#filtering). Refer to the [Person API Documentation](/person-api/filter-query-parameter) for more information about the `filter` query param.",
"required": false,
"style": "deepObject",
"explode": true,
"schema": {
"type": "object",
"additionalProperties": false,
"properties": {
"attribute": {
"type": "string",
"example": "firstName"
}
}
}
},
{
"name": "fields",
"in": "query",
"description": "Specify the list of fields you would like to return for each resource type. For example, `fields[people]=firstName,lastName` will just return the names for people. If you are including related resources with 'includes' you can also specify fields on those resources as well. For example, `includes=jobs&fields[people]=jobs&fields[jobs]=title` will just return titles for jobs. See [Sparse Fieldsets](https://jsonapi.org/format/#fetching-sparse-fieldsets) for more details.",
"required": false,
"style": "deepObject",
"explode": true,
"schema": {
"type": "object",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"example": "people"
}
}
}
},
{
"name": "include",
"in": "query",
"description": "[include related resources](https://jsonapi.org/format/#fetching-includes). The resources to include need to be direct relationships. Nested relationships are not supported. For example, `include=jobs,identifiers` is supported but `include=person.jobs` is not supported.",
"schema": {
"type": "string"
}
},
{
"name": "page",
"in": "query",
"description": "Define options for pagination of responses. For example, `page[size]=5&page[after]=400&page[before]=800` will return a response with data about 5 people whose `id` value falls after `400` but before `800`. So `page[size]` determines the number of people resources in a response, `page[after]` is the ID of the person at the end of the previous page, `page[before]` is the ID of the person at the start of the next page. Offset pagination is also supported using `page[number]` parameter (example: `page[number]=4&page[size]=10`), but it is disabled by default. The `page[number]` determines the page to display. Offset pagination has significantly worse performance than cursor pagination, so it should only be used by applications that can't support cursor pagination. Contact the developers if you would like to enable it.",
"required": false,
"style": "deepObject",
"explode": true,
"schema": {
"type": "object",
"properties": {
"size": {
"type": "integer",
"example": 50,
"maximum": 1000,
"minimum": 1,
"default": 100,
"description": "Size of page for paginated results."
},
"after": {
"type": "string",
"description": "An ephemeral identifier used only in the Person API to adhere to the [JSON:API specification](https://jsonapi.org/format/#document-resource-object-identification). This ID may change if a person is split into two people or two people are merged into one person. This ID is used for paginating results or following other links returned in the API response. This ID should not be stored in a consuming system. Concatenating parts of the URL to form a link is discouraged. Instead, use the fully-formed links returned in an API response.",
"example": "12345"
},
"before": {
"type": "string",
"description": "An ephemeral identifier used only in the Person API to adhere to the [JSON:API specification](https://jsonapi.org/format/#document-resource-object-identification). This ID may change if a person is split into two people or two people are merged into one person. This ID is used for paginating results or following other links returned in the API response. This ID should not be stored in a consuming system. Concatenating parts of the URL to form a link is discouraged. Instead, use the fully-formed links returned in an API response.",
"example": "12345"
},
"number": {
"type": "integer",
"example": 1,
"minimum": 1,
"description": "Page number for paginated results. This parameter is disabled by default. Contact the developers if you would like to enable it."
}
}
}
}
],
"responses": {
"200": {
"description": "A collection of people",
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"required": [
"data",
"links"
],
"properties": {
"data": {
"description": "A collection of people",
"type": "array",
"items": {
"description": "A person",
"type": "object",
"required": [
"type",
"id",
"attributes",
"relationships",
"links",
"meta"
],
"properties": {
"type": {
"type": "string",
"example": "people"
},
"id": {
"type": "string",
"description": "An ephemeral identifier used only in the Person API to adhere to the [JSON:API specification](https://jsonapi.org/format/#document-resource-object-identification). This ID may change if a person is split into two people or two people are merged into one person. This ID is used for paginating results or following other links returned in the API response. This ID should not be stored in a consuming system. Concatenating parts of the URL to form a link is discouraged. Instead, use the fully-formed links returned in an API response.",
"example": "12345"
},
"attributes": {
"required": [
"firstName",
"lastName",
"emailAddress",
"officeAddress",
"officePhoneNumber"
],
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
"firstName": {
"type": "string",
"example": "John",
"description": "First name, derived from the person's current UW affiliations."
},
"lastName": {
"type": "string",
"example": "Smith",
"description": "Last name, derived from the person's current UW affiliations."
},
"emailAddress": {
"type": "string",
"example": "john.smith@wisc.edu",
"description": "The email address this person has designated as their primary, if set. Otherwise, their Campus Business Email, or other email derived from their current UW affiliations."
},
"officeAddress": {
"type": "string",
"description": "Primary work-related address derived from the person's current UW affiliations. May or may not be a fully-formed street address.",
"example": "1210 W. Dayton Street Madison, WI 53706-1613",
"nullable": true
},
"officePhoneNumber": {
"type": "string",
"example": "608-262-1204",
"description": "Primary work-related phone number derived from the person's current UW affiliations. May or may not be associated with the officeAddress.",
"nullable": true
}
"required": [
"identifiers",
"jobs",
"names",
"wiscard"
],
"identifiers": {
"description": "A generic relationship object",
"type": "object",
"properties": {
"links": {
"related": {
"type": "string",
"example": "https://api.wisc.edu/link/to/related/object"
}
},
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"example": "sampleType"
},
"id": {
"type": "string",
"example": "sampleId"
},
"jobs": {
"description": "A generic relationship object",
"type": "object",
"properties": {
"links": {
"related": {
"type": "string",
"example": "https://api.wisc.edu/link/to/related/object"
}
},
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"example": "sampleType"
},
"id": {
"type": "string",
"example": "sampleId"
},
"names": {
"description": "A generic relationship object",
"type": "object",
"properties": {
"links": {
"related": {
"type": "string",
"example": "https://api.wisc.edu/link/to/related/object"
}
},
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"example": "sampleType"
},
"id": {
"type": "string",
"example": "sampleId"
},
"wiscard": {
"description": "A generic relationship object",
"type": "object",
"properties": {
"links": {
"related": {
"type": "string",
"example": "https://api.wisc.edu/link/to/related/object"
}
"type": {
"type": "string",
"example": "sampleType"
},
"id": {
"type": "string",
"example": "sampleId"
}
},
"links": {
"description": "The link to access a resource itself",
"self": {
"type": "string",
"example": "https://api.wisc.edu/link/to/self"
}
},
"meta": {
"type": "object",
"properties": {
"ferpa": {
"type": "boolean",
"example": false,
"description": "Indicates whether or not a student has elected FERPA coverage on one or more of their attributes. Please see https://registrar.wisc.edu/ferpa/ for more details about how to handle FERPA data."
},
"ferpaAttributes": {
"type": "array",
"items": {
"type": "string"
"description": "Not currently used."
},
"privateAttributes": {
"type": "array",
"items": {
"type": "string"
"description": "Not currently used."
}
"links": {
"description": "Self and pagination links",
"allOf": [
{
"description": "The link to access a resource itself",
"type": "object",
"properties": {
"self": {
"type": "string",
"example": "https://api.wisc.edu/link/to/self"
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
}
},
{
"description": "The links associated with a paginated collection",
"type": "object",
"properties": {
"self": {
"description": "The current page of data",
"type": "string",
"format": "uri-reference",
"example": "https://api.wisc.edu/people?page[after]=6"
},
"prev": {
"description": "The previous page of data",
"type": "string",
"format": "uri-reference",
"example": "https://api.wisc.edu/people?page[before]=7"
},
"next": {
"description": "The next page of data",
"type": "string",
"format": "uri-reference",
"example": "https://api.wisc.edu/people?page[after]=8"
},
"first": {
"description": "Available when using offset pagination. The first page of data",
"type": "string",
"format": "uri-reference",
"example": "https://api.wisc.edu/people?page[number]=1"
},
"last": {
"description": "Available when using offset pagination. The last page of data",
"type": "string",
"format": "uri-reference",
"example": "https://api.wisc.edu/people?page[number]=10"
"meta": {
"type": "object",
"properties": {
"paging": {
"type": "object",
"properties": {
"totalPeople": {
"type": "integer",
"example": 100,
"description": "The total number of people available for the collection"
},
"example": 100,
"description": "The total number of people in the collection"
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
"included": {
"description": "Included related resources",
"type": "array",
"items": {
"description": "A generic resource object",
"type": "object",
"properties": {
"type": {
"type": "string",
"example": "sampleType"
},
"id": {
"type": "string",
"example": "sampleId"
},
"attributes": {
"type": "object",
"properties": {
"attribute1": {
"type": "string",
"example": "sampleStringAttribute"
},
"attribute2": {
"type": "number",
"example": 123
}
}
},
"relationships": {
"type": "object",
"properties": {
"relatedResource": {
"description": "A generic relationship object",
"type": "object",
"properties": {
"links": {
"related": {
"type": "string",
"example": "https://api.wisc.edu/link/to/related/object"
}
"type": {
"type": "string",
"example": "sampleType"
},
"id": {
"type": "string",
"example": "sampleId"
}
}
}
},
"links": {
"description": "The link to access a resource itself",
"type": "object",
"properties": {
"self": {
"type": "string",
"example": "https://api.wisc.edu/link/to/self"
}
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
}
},
"examples": {
"example-people": {
"value": {
"data": [
{
"attributes": {
"emailAddress": "john.smith@wisc.edu",
"firstName": "John",
"lastName": "Smith",
"officeAddress": "1210 W Dayton St, Madison, WI 53706",
"officePhoneNumber": "608-555-1234"
},
"id": "100",
"links": {
"self": "https://api.wisc.edu/people/100"
},
"meta": {
"ferpa": false,
"ferpaAttributes": [],
"privateAttributes": []
},
"relationships": {
"identifiers": {
"data": [
{
"id": "100",
"type": "identifiers"
}
],
"links": {
"related": "https://api.wisc.edu/people/100/identifiers"
}
},
"jobs": {
"data": [
{
"id": "100",
"type": "jobs"
}
],
"links": {
"related": "https://api.wisc.edu/people/100/jobs"
}
},
"names": {
"data": [
{
"id": "100",
"type": "names"
}
],
"links": {
"related": "https://api.wisc.edu/people/100/names"
}
},
"wiscard": {
"data": {
"id": "100",
"type": "wiscard"
},
"links": {
"related": "https://api.wisc.edu/people/100/wiscard"
}
}
},
"type": "people"
}
],
"links": {
"self": "https://api.wisc.edu/people"
}
}
}
}
}
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
},
"400": {
"description": "A bad request.",
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"description": "An error",
"type": "object",
"properties": {
"status": {
"type": "integer",
"example": 400
},
"title": {
"type": "string",
"example": "Error title"
},
"detail": {
"type": "string",
"example": "Additional details about the error"
},
"links": {
"type": "object"
},
"meta": {
"type": "object"
},
"source": {
"type": "object"
}
}
}
}
},
"examples": {
"application/vnd.api+json": {
"value": {
"errors": [
{
"id": null,
"links": {},
"meta": {},
"source": {},
"status": 400,
"title": "Bad Request",
"detail": "Invalid properties in query parameters - resource type 'people' has no attribute 'invalid'."
}
]
}
}
},
"401": {
"description": "Incorrect or expired OAuth token.",
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"description": "An error",
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
"properties": {
"status": {
"type": "integer",
"example": 400
},
"title": {
"type": "string",
"example": "Error title"
},
"detail": {
"type": "string",
"example": "Additional details about the error"
},
"links": {
"type": "object"
},
"meta": {
"type": "object"
},
"source": {
"type": "object"
}
}
}
}
}
},
"examples": {
"unauthorized-response": {
"value": {
"errors": [
{
"status": 401,
"title": "Unauthorized",
"detail": "Invalid OAuth authentication - InvalidAccessToken"
}
]
}
}
}
}
}
},
"406": {
"description": "Servers respond with a 406 Not Acceptable status code if a request’s Accept header contains the JSON:API media type and all instances of that media type are modified with media type parameters.",
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"description": "An error",
"type": "object",
"properties": {
"status": {
"type": "integer",
"example": 400
},
"title": {
"type": "string",
"example": "Error title"
},
"detail": {
"type": "string",
"example": "Additional details about the error"
},
"links": {
"type": "object"
},
"meta": {
"type": "object"
},
"source": {
"type": "object"
}
}
}
}
}
},
"examples": {
"not-acceptable-example": {
"value": {
"errors": [
{
"status": 406,
"title": "Not Acceptable",
"detail": "Request's Accept header contained the JSON:API media type and all instances of that media type were modified with media type parameters."
}
]
}
}
}
}
}
},
"429": {
"description": "The API quota has been exceeded.",
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"description": "An error",
"type": "object",
"properties": {
"status": {
"type": "integer",
"example": 400
},
"title": {
"type": "string",
"example": "Error title"
},
"detail": {
"type": "string",
"example": "Additional details about the error"
},
"links": {
"type": "object"
},
"meta": {
"type": "object"
},
"source": {
"type": "object"
}
}
}
}
}
},
"examples": {
"not-found-example": {
"value": {
"errors": [
{
"status": 429,
"title": "Too Many Requests",
"detail": "The quota has been exceeded."
}
]
}
}
}
}
}
},
"500": {
"description": "An unexpected error.",
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"description": "An error",
"type": "object",
"properties": {
"status": {
"type": "integer",
"example": 400
},
"title": {
"type": "string",
"example": "Error title"
},
"detail": {
"type": "string",
"example": "Additional details about the error"
},
"links": {
"type": "object"
},
"meta": {
"type": "object"
},
"source": {
"type": "object"
}
}
}
}
}
},
"examples": {
"not-found-example": {
"value": {
"errors": [
{
"status": 500,
"title": "Internal Server Error",
"detail": "Something went wrong in the server-side."
}
]
}
}
}
}
}
}
}
}
},
"/people/{id}": {
"get": {
"description": "Get a person. It is not recommended to manually build this URL or other URLs that contain path parameters, for example, by using concatenation. Instead, use the fully-qualified links returned in other resources to use this resource and other \"Get By ID\" resources.",
"summary": "Get a person.",
"operationId": "get_person",
"tags": [
"people"
],
"parameters": [
{
"name": "id",
"description": "ID of a person. This parameter should not be manually built/concatenated, but instead be used by following the fully-formed links returned in an API response. To get a person by an ID, use query parameters to search by a specific identifier. Example: /people?filter[identifiers.name]=netId&filter[identifiers.value]=bbadger",
"in": "path",
"example": "700",
"required": true,
"schema": {
"type": "string",
"description": "An ephemeral identifier used only in the Person API to adhere to the [JSON:API specification](https://jsonapi.org/format/#document-resource-object-identification). This ID may change if a person is split into two people or two people are merged into one person. This ID is used for paginating results or following other links returned in the API response. This ID should not be stored in a consuming system. Concatenating parts of the URL to form a link is discouraged. Instead, use the fully-formed links returned in an API response.",
"example": "12345"
}
},
{
"name": "include",
"in": "query",
"description": "[include related resources](https://jsonapi.org/format/#fetching-includes). The resources to include need to be direct relationships. Nested relationships are not supported. For example, `include=jobs,identifiers` is supported but `include=person.jobs` is not supported.",
"schema": {
"type": "string"
}
},
{
"name": "fields",
"in": "query",
"description": "Specify the list of fields you would like to return for each resource type. For example, `fields[people]=firstName,lastName` will just return the names for people. If you are including related resources with 'includes' you can also specify fields on those resources as well. For example, `includes=jobs&fields[people]=jobs&fields[jobs]=title` will just return titles for jobs. See [Sparse Fieldsets](https://jsonapi.org/format/#fetching-sparse-fieldsets) for more details.",
"required": false,
"style": "deepObject",
"explode": true,
"schema": {
"type": "object",
"additionalProperties": false,
"properties": {
"type": {
"type": "string",
"example": "people"
}
}
}
}
],
"responses": {
"200": {
"description": "A single person",
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"required": [
"data",
"links"
],
"properties": {
"data": {
"description": "A person",
"type": "object",
"required": [
"type",
"id",
"attributes",
"relationships",
"links",
"meta"
],
"properties": {
"type": {
"type": "string",
"example": "people"
},
"id": {
"type": "string",
"description": "An ephemeral identifier used only in the Person API to adhere to the [JSON:API specification](https://jsonapi.org/format/#document-resource-object-identification). This ID may change if a person is split into two people or two people are merged into one person. This ID is used for paginating results or following other links returned in the API response. This ID should not be stored in a consuming system. Concatenating parts of the URL to form a link is discouraged. Instead, use the fully-formed links returned in an API response.",
"example": "12345"
},
"attributes": {
"type": "object",
"required": [
"firstName",
"lastName",
"emailAddress",
"officeAddress",
"officePhoneNumber"
"type": "string",
"example": "John",
"description": "First name, derived from the person's current UW affiliations."
"type": "string",
"example": "Smith",
"description": "Last name, derived from the person's current UW affiliations."
"type": "string",
"example": "john.smith@wisc.edu",
"description": "The email address this person has designated as their primary, if set. Otherwise, their Campus Business Email, or other email derived from their current UW affiliations."
"type": "string",
"description": "Primary work-related address derived from the person's current UW affiliations. May or may not be a fully-formed street address.",
"example": "1210 W. Dayton Street Madison, WI 53706-1613",
"nullable": true
"type": "string",
"example": "608-262-1204",
"description": "Primary work-related phone number derived from the person's current UW affiliations. May or may not be associated with the officeAddress.",
"nullable": true
}
},
"relationships": {
"type": "object",
"required": [
"description": "A generic relationship object",
"type": "object",
"properties": {
"links": {
"type": "object",