Skip to content

Affiliated Organizations

Operations Summary

Method Endpoint Description
Core CRUD
GET /api/affiliated-organizations/ List Affiliated Organizations
GET /api/affiliated-organizations/{uuid}/ Retrieve
POST /api/affiliated-organizations/ Create
PUT /api/affiliated-organizations/{uuid}/ Update
PATCH /api/affiliated-organizations/{uuid}/ Partial Update
DELETE /api/affiliated-organizations/{uuid}/ Delete
Other Actions
GET /api/affiliated-organizations/report/ Get affiliated organizations report
GET /api/affiliated-organizations/{uuid}/stats/ Get affiliated organization statistics

Core CRUD

List Affiliated Organizations

1
2
3
4
http \
  GET \
  https://api.example.com/api/affiliated-organizations/ \
  Authorization:"Token YOUR_API_TOKEN"
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.models.affiliated_organization_field_enum import AffiliatedOrganizationFieldEnum # (1)
from waldur_api_client.api.affiliated_organizations import affiliated_organizations_list # (2)

client = AuthenticatedClient(
    base_url="https://api.example.com", token="YOUR_API_TOKEN"
)
response = affiliated_organizations_list.sync(client=client)

for item in response:
    print(item)
  1. Model Source: AffiliatedOrganizationFieldEnum
  2. API Source: affiliated_organizations_list
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
import { affiliatedOrganizationsList } from 'waldur-js-client';

try {
  const response = await affiliatedOrganizationsList({
  auth: "Token YOUR_API_TOKEN"
});
  console.log('Success:', response);
} catch (error) {
  console.error('Error:', error);
}
Name Type Description
abbreviation string Abbreviation
code string Code
country string Country
default_for_customer string (uuid) Limit to a customer's default affiliation list
field array
name string Name
name_exact string Name (exact)
o string Which field to use when ordering the results.
page integer A page number within the paginated result set.
page_size integer Number of results to return per page.
query string Search

200 -

The response body is an array of objects, where each object has the following structure:

Field Type Description
uuid string (uuid)
url string (uri)
name string
code string Unique short identifier, e.g. CERN, EMBL.
abbreviation string
description string
email string (email)
homepage string (uri)
country string
address string
created string (date-time)
modified string (date-time)
projects_count integer Number of active projects affiliated with this organization

Retrieve

1
2
3
4
http \
  GET \
  https://api.example.com/api/affiliated-organizations/a1b2c3d4-e5f6-7890-abcd-ef1234567890/ \
  Authorization:"Token YOUR_API_TOKEN"
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.models.affiliated_organization_field_enum import AffiliatedOrganizationFieldEnum # (1)
from waldur_api_client.api.affiliated_organizations import affiliated_organizations_retrieve # (2)

client = AuthenticatedClient(
    base_url="https://api.example.com", token="YOUR_API_TOKEN"
)
response = affiliated_organizations_retrieve.sync(
    uuid="a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    client=client
)

print(response)
  1. Model Source: AffiliatedOrganizationFieldEnum
  2. API Source: affiliated_organizations_retrieve
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
import { affiliatedOrganizationsRetrieve } from 'waldur-js-client';

try {
  const response = await affiliatedOrganizationsRetrieve({
  auth: "Token YOUR_API_TOKEN",
  path: {
    "uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
  }
});
  console.log('Success:', response);
} catch (error) {
  console.error('Error:', error);
}
Name Type Required
uuid string (uuid)
Name Type
field array

200 -

Field Type Description
uuid string (uuid)
url string (uri)
name string
code string Unique short identifier, e.g. CERN, EMBL.
abbreviation string
description string
email string (email)
homepage string (uri)
country string
address string
created string (date-time)
modified string (date-time)
projects_count integer Number of active projects affiliated with this organization

Create

1
2
3
4
5
6
http \
  POST \
  https://api.example.com/api/affiliated-organizations/ \
  Authorization:"Token YOUR_API_TOKEN" \
  name="my-awesome-affiliated-organization" \
  code="string-value"
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.models.affiliated_organization_request import AffiliatedOrganizationRequest # (1)
from waldur_api_client.api.affiliated_organizations import affiliated_organizations_create # (2)

client = AuthenticatedClient(
    base_url="https://api.example.com", token="YOUR_API_TOKEN"
)

body_data = AffiliatedOrganizationRequest(
    name="my-awesome-affiliated-organization",
    code="string-value"
)
response = affiliated_organizations_create.sync(
    client=client,
    body=body_data
)

print(response)
  1. Model Source: AffiliatedOrganizationRequest
  2. API Source: affiliated_organizations_create
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
import { affiliatedOrganizationsCreate } from 'waldur-js-client';

try {
  const response = await affiliatedOrganizationsCreate({
  auth: "Token YOUR_API_TOKEN",
  body: {
    "name": "my-awesome-affiliated-organization",
    "code": "string-value"
  }
});
  console.log('Success:', response);
} catch (error) {
  console.error('Error:', error);
}
Field Type Required Description
name string
code string Unique short identifier, e.g. CERN, EMBL.
abbreviation string
description string
email string (email)
homepage string (uri)
country string
address string

201 -

Field Type Description
uuid string (uuid)
url string (uri)
name string
code string Unique short identifier, e.g. CERN, EMBL.
abbreviation string
description string
email string (email)
homepage string (uri)
country string
address string
created string (date-time)
modified string (date-time)
projects_count integer Number of active projects affiliated with this organization

Update

1
2
3
4
5
6
http \
  PUT \
  https://api.example.com/api/affiliated-organizations/a1b2c3d4-e5f6-7890-abcd-ef1234567890/ \
  Authorization:"Token YOUR_API_TOKEN" \
  name="my-awesome-affiliated-organization" \
  code="string-value"
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.models.affiliated_organization_request import AffiliatedOrganizationRequest # (1)
from waldur_api_client.api.affiliated_organizations import affiliated_organizations_update # (2)

client = AuthenticatedClient(
    base_url="https://api.example.com", token="YOUR_API_TOKEN"
)

body_data = AffiliatedOrganizationRequest(
    name="my-awesome-affiliated-organization",
    code="string-value"
)
response = affiliated_organizations_update.sync(
    uuid="a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    client=client,
    body=body_data
)

print(response)
  1. Model Source: AffiliatedOrganizationRequest
  2. API Source: affiliated_organizations_update
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
import { affiliatedOrganizationsUpdate } from 'waldur-js-client';

try {
  const response = await affiliatedOrganizationsUpdate({
  auth: "Token YOUR_API_TOKEN",
  path: {
    "uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
  },
  body: {
    "name": "my-awesome-affiliated-organization",
    "code": "string-value"
  }
});
  console.log('Success:', response);
} catch (error) {
  console.error('Error:', error);
}
Name Type Required
uuid string (uuid)
Field Type Required Description
name string
code string Unique short identifier, e.g. CERN, EMBL.
abbreviation string
description string
email string (email)
homepage string (uri)
country string
address string

200 -

Field Type Description
uuid string (uuid)
url string (uri)
name string
code string Unique short identifier, e.g. CERN, EMBL.
abbreviation string
description string
email string (email)
homepage string (uri)
country string
address string
created string (date-time)
modified string (date-time)
projects_count integer Number of active projects affiliated with this organization

Partial Update

1
2
3
4
http \
  PATCH \
  https://api.example.com/api/affiliated-organizations/a1b2c3d4-e5f6-7890-abcd-ef1234567890/ \
  Authorization:"Token YOUR_API_TOKEN"
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.models.patched_affiliated_organization_request import PatchedAffiliatedOrganizationRequest # (1)
from waldur_api_client.api.affiliated_organizations import affiliated_organizations_partial_update # (2)

client = AuthenticatedClient(
    base_url="https://api.example.com", token="YOUR_API_TOKEN"
)

body_data = PatchedAffiliatedOrganizationRequest()
response = affiliated_organizations_partial_update.sync(
    uuid="a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    client=client,
    body=body_data
)

print(response)
  1. Model Source: PatchedAffiliatedOrganizationRequest
  2. API Source: affiliated_organizations_partial_update
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
import { affiliatedOrganizationsPartialUpdate } from 'waldur-js-client';

try {
  const response = await affiliatedOrganizationsPartialUpdate({
  auth: "Token YOUR_API_TOKEN",
  path: {
    "uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
  }
});
  console.log('Success:', response);
} catch (error) {
  console.error('Error:', error);
}
Name Type Required
uuid string (uuid)
Field Type Required Description
name string
code string Unique short identifier, e.g. CERN, EMBL.
abbreviation string
description string
email string (email)
homepage string (uri)
country string
address string

200 -

Field Type Description
uuid string (uuid)
url string (uri)
name string
code string Unique short identifier, e.g. CERN, EMBL.
abbreviation string
description string
email string (email)
homepage string (uri)
country string
address string
created string (date-time)
modified string (date-time)
projects_count integer Number of active projects affiliated with this organization

Delete

1
2
3
4
http \
  DELETE \
  https://api.example.com/api/affiliated-organizations/a1b2c3d4-e5f6-7890-abcd-ef1234567890/ \
  Authorization:"Token YOUR_API_TOKEN"
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.api.affiliated_organizations import affiliated_organizations_destroy # (1)

client = AuthenticatedClient(
    base_url="https://api.example.com", token="YOUR_API_TOKEN"
)
response = affiliated_organizations_destroy.sync(
    uuid="a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    client=client
)

print(response)
  1. API Source: affiliated_organizations_destroy
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
import { affiliatedOrganizationsDestroy } from 'waldur-js-client';

try {
  const response = await affiliatedOrganizationsDestroy({
  auth: "Token YOUR_API_TOKEN",
  path: {
    "uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
  }
});
  console.log('Success:', response);
} catch (error) {
  console.error('Error:', error);
}
Name Type Required
uuid string (uuid)

204 - No response body


Other Actions

Get affiliated organizations report

Staff-only report showing aggregated data for all affiliated organizations plus an unaffiliated row.

1
2
3
4
http \
  GET \
  https://api.example.com/api/affiliated-organizations/report/ \
  Authorization:"Token YOUR_API_TOKEN"
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.api.affiliated_organizations import affiliated_organizations_report_list # (1)

client = AuthenticatedClient(
    base_url="https://api.example.com", token="YOUR_API_TOKEN"
)
response = affiliated_organizations_report_list.sync(client=client)

for item in response:
    print(item)
  1. API Source: affiliated_organizations_report_list
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
import { affiliatedOrganizationsReportList } from 'waldur-js-client';

try {
  const response = await affiliatedOrganizationsReportList({
  auth: "Token YOUR_API_TOKEN"
});
  console.log('Success:', response);
} catch (error) {
  console.error('Error:', error);
}
Name Type Description
abbreviation string Abbreviation
code string Code
country string Country
default_for_customer string (uuid) Limit to a customer's default affiliation list
name string Name
name_exact string Name (exact)
o string Which field to use when ordering the results.
page integer A page number within the paginated result set.
page_size integer Number of results to return per page.
query string Search

200 -

The response body is an array of objects, where each object has the following structure:

Field Type
org_uuid string (uuid)
org_name string
org_abbreviation string
projects_count integer
resources_count integer
estimated_cost string (decimal)

Get affiliated organization statistics

Returns permission-filtered statistics for this affiliated organization.

1
2
3
4
http \
  GET \
  https://api.example.com/api/affiliated-organizations/a1b2c3d4-e5f6-7890-abcd-ef1234567890/stats/ \
  Authorization:"Token YOUR_API_TOKEN"
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
from waldur_api_client.client import AuthenticatedClient
from waldur_api_client.api.affiliated_organizations import affiliated_organizations_stats_retrieve # (1)

client = AuthenticatedClient(
    base_url="https://api.example.com", token="YOUR_API_TOKEN"
)
response = affiliated_organizations_stats_retrieve.sync(
    uuid="a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    client=client
)

print(response)
  1. API Source: affiliated_organizations_stats_retrieve
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
import { affiliatedOrganizationsStatsRetrieve } from 'waldur-js-client';

try {
  const response = await affiliatedOrganizationsStatsRetrieve({
  auth: "Token YOUR_API_TOKEN",
  path: {
    "uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
  }
});
  console.log('Success:', response);
} catch (error) {
  console.error('Error:', error);
}
Name Type Required
uuid string (uuid)

200 -

Field Type
active_projects_count integer
resources_count integer
estimated_monthly_cost string (decimal)