Accept multiple cards for each user

This commit is contained in:
2018-12-03 23:17:43 -07:00
parent 2812685868
commit d8ec4b30c8
3 changed files with 7 additions and 7 deletions
+3 -3
View File
@@ -202,7 +202,7 @@ Here you can authorize users on tools or make them another lockout admin.
#### PUT `/update-cards/`
Send a dictionary of username=card_number pairs to update any profiles already in the system. Users not already registered will be ignored.
Send a dictionary of username=card_number,card_number,card_number pairs to update any profiles already in the system. Users not already registered will be ignored.
Responds with the number of profiles updated.
@@ -212,7 +212,7 @@ Example PUT data:
```
{
"tanner.collin": "00000A4123",
"tanner.collin": "00000A4123,00000A4124,00000A4125",
"matthew.mulrooney": "00000B8567",
"not-a-member": "539830843A"
}
@@ -227,5 +227,5 @@ Example response:
Example request:
```
curl -X PUT -H "Authorization: Token 9944b09199c62bcf9418ad846dd0e4bbdfc6ee4b" -d tanner.collin=00000A4123 -d matthew.mulrooney=00000B8567 http://tools-auth.protospace.ca/update-cards/
curl -X PUT -H "Authorization: Token 9944b09199c62bcf9418ad846dd0e4bbdfc6ee4b" -d tanner.collin=00000A4123,00000A4124 -d matthew.mulrooney=00000B8567 http://tools-auth.protospace.ca/update-cards/
```