Create claim activity¶
This operation posts a new Activity record against a Guidewire claim through ActivityDataApiClient.CreateActivityRequest, using the shared base-URL/auth pipeline and throwing on a non-success response.
| Field | Value |
|---|---|
| Operation ID | OP-SDG-02 |
| Trigger | Caller invokes CreateActivityRequest(claimId, Activity) |
| Inputs | Claim id, Activity |
| Outputs | HTTP 2xx response, or a thrown exception |
| Primary components | ActivityDataApiClient.CreateActivityRequest |
| Entry point | Data/SAIF.Data.Guidewire/Clients/ActivityDataApiClient.cs |
Steps¶
- Resolve the client's base URL (
cc.activitydata.api.url.v1) and Basic-auth header (cc.gwcreds). - Set
BaseAddressfromGetConfigSetting(UrlKey). - On first request, compute the system hash and set the
Authorization: Basicheader fromGetSecureConfigSetting(AuthKey, hash).
Origin: Step 1 is implemented in Resolve base URL and authenticate (
SAIF.Data.Guidewire) and executed on behalf of this operation. 2. Serialize theActivitypayload with null properties ignored. (SDG-BR-010) 3. POST the serialized payload toactivity/claim/{claimId}. 4. If the response is non-success, throw an exception including the HTTP status code and response content. Other exceptions raised during the call are wrapped. (SDG-BR-011) - On failure: caller receives the wrapped/thrown exception; no partial activity is assumed created.
Process flow¶
The following diagram visualizes this operation's control flow.
flowchart TD
Start([Caller invokes CreateActivityRequest]) --> S1["Resolve base URL and<br>Basic-auth header"]
S1 --> S2["Serialize Activity,<br>omit null properties"]
S2 --> S3["POST activity/claim/{claimId}"]
S3 --> S4{"Non-success status?"}
S4 -->|Yes| EndErr([Throw with status and content])
S4 -->|No| EndOk([Return success])
Failure and edge-case behavior¶
- A non-success HTTP status throws with the status code and response content, and other exceptions are wrapped, so callers must handle exceptions rather than inspect a return status.
Related documentation¶
Sources¶
Data/SAIF.Data.Guidewire/Clients/ActivityDataApiClient.csData/SAIF.Data.Guidewire/Clients/HttpClientBase.csData/SAIF.Data.Guidewire/Models/ActvityDataApi/Activity.cs