MCPcopy
hub / github.com/Agenta-AI/agenta / update_organization

Method update_organization

sdk/agenta/client/client.py:610–686  ·  view source on GitHub ↗

Parameters ---------- org_id : str name : typing.Optional[str] description : typing.Optional[str] updated_at : typing.Optional[str] request_options : typing.Optional[RequestOptions] Request-specific configuration. Retu

(
        self,
        org_id: str,
        *,
        name: typing.Optional[str] = OMIT,
        description: typing.Optional[str] = OMIT,
        updated_at: typing.Optional[str] = OMIT,
        request_options: typing.Optional[RequestOptions] = None,
    )

Source from the content-addressed store, hash-verified

608 raise ApiError(status_code=_response.status_code, body=_response_json)
609
610 def update_organization(
611 self,
612 org_id: str,
613 *,
614 name: typing.Optional[str] = OMIT,
615 description: typing.Optional[str] = OMIT,
616 updated_at: typing.Optional[str] = OMIT,
617 request_options: typing.Optional[RequestOptions] = None,
618 ) -> typing.Optional[typing.Any]:
619 """
620 Parameters
621 ----------
622 org_id : str
623
624 name : typing.Optional[str]
625
626 description : typing.Optional[str]
627
628 updated_at : typing.Optional[str]
629
630 request_options : typing.Optional[RequestOptions]
631 Request-specific configuration.
632
633 Returns
634 -------
635 typing.Optional[typing.Any]
636 Successful Response
637
638 Examples
639 --------
640 from agenta import AgentaApi
641
642 client = AgentaApi(
643 api_key="YOUR_API_KEY",
644 base_url="https://yourhost.com/path/to/api",
645 )
646 client.update_organization(
647 org_id="org_id",
648 )
649 """
650 _response = self._client_wrapper.httpx_client.request(
651 f"organizations/{jsonable_encoder(org_id)}",
652 method="PUT",
653 json={
654 "name": name,
655 "description": description,
656 "updated_at": updated_at,
657 },
658 headers={
659 "content-type": "application/json",
660 },
661 request_options=request_options,
662 omit=OMIT,
663 )
664 try:
665 if 200 <= _response.status_code < 300:
666 return typing.cast(
667 typing.Optional[typing.Any],

Callers

nothing calls this directly

Calls 6

jsonable_encoderFunction · 0.90
parse_obj_asFunction · 0.85
jsonMethod · 0.80
ApiErrorClass · 0.50
requestMethod · 0.45

Tested by

no test coverage detected