Class AdBreakService.AdBreakServiceBase
Base class for server-side implementations of AdBreakService
Namespace: Google.Ads.AdManager.V1
Assembly: Google.Ads.AdManager.V1.dll
Syntax
[BindServiceMethod(typeof(AdBreakService), "BindService")]
public abstract class AdBreakService.AdBreakServiceBase
Methods
CreateAdBreak(CreateAdBreakRequest, ServerCallContext)
API to create an AdBreak object.
Informs DAI of an upcoming ad break for a live stream event, with an
optional expected start time. DAI will begin decisioning ads for the break
shortly before the expected start time, if provided. Each live stream
event can only have one incomplete ad break at any given time. The next ad
break can be scheduled after the previous ad break has started serving,
indicated by its state being
[COMPLETE][google.ads.admanager.v1.AdBreakStateEnum.AdBreakState.COMPLETE],
or it has been deleted.
This method cannot be used if the LiveStreamEvent has
prefetching ad breaks
enabled
or the event is not active. If a LiveStreamEvent is deactivated after
creating an ad break and before the ad break is complete, the ad break
is discarded.
An ad break's state is complete when the following occurs:
- Full service DAI: after a matching ad break shows in the
LiveStreamEventmanifest only when the ad break has started decisioning. - Pod Serving: after the ad break is requested using the ad break ID or break sequence.
Declaration
public virtual Task<AdBreak> CreateAdBreak(CreateAdBreakRequest request, ServerCallContext context)
Parameters
| Type | Name | Description |
|---|---|---|
| CreateAdBreakRequest | request | The request received from the client. |
| ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
| Type | Description |
|---|---|
| Task<AdBreak> | The response to send back to the client (wrapped by a task). |
DeleteAdBreak(DeleteAdBreakRequest, ServerCallContext)
API to delete an AdBreak object.
Deletes and cancels an incomplete ad break, mitigating the need to wait
for the current break to serve before recreating an ad break. You can
delete an ad break that has not started serving or seen in manifests,
indicated by its state being
[SCHEDULED][google.ads.admanager.v1.AdBreakStateEnum.AdBreakState.SCHEDULED]
or
[DECISIONED][google.ads.admanager.v1.AdBreakStateEnum.AdBreakState.DECISIONED].
Declaration
public virtual Task<Empty> DeleteAdBreak(DeleteAdBreakRequest request, ServerCallContext context)
Parameters
| Type | Name | Description |
|---|---|---|
| DeleteAdBreakRequest | request | The request received from the client. |
| ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
| Type | Description |
|---|---|
| Task<Empty> | The response to send back to the client (wrapped by a task). |
GetAdBreak(GetAdBreakRequest, ServerCallContext)
API to retrieve an AdBreak object.
Query an ad break by its resource name or custom asset key. Check the
resource's breakState field to determine its state.
Declaration
public virtual Task<AdBreak> GetAdBreak(GetAdBreakRequest request, ServerCallContext context)
Parameters
| Type | Name | Description |
|---|---|---|
| GetAdBreakRequest | request | The request received from the client. |
| ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
| Type | Description |
|---|---|
| Task<AdBreak> | The response to send back to the client (wrapped by a task). |
ListAdBreaks(ListAdBreaksRequest, ServerCallContext)
API to retrieve a list of AdBreak objects.
By default, when no orderBy query parameter is specified, ad breaks are
ordered reverse chronologically. However, ad breaks with a 'breakState' of
'SCHEDULED' or 'DECISIONED' are prioritized and appear first.
Declaration
public virtual Task<ListAdBreaksResponse> ListAdBreaks(ListAdBreaksRequest request, ServerCallContext context)
Parameters
| Type | Name | Description |
|---|---|---|
| ListAdBreaksRequest | request | The request received from the client. |
| ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
| Type | Description |
|---|---|
| Task<ListAdBreaksResponse> | The response to send back to the client (wrapped by a task). |
UpdateAdBreak(UpdateAdBreakRequest, ServerCallContext)
API to update an AdBreak object.
Modify an ad break when its state is
[SCHEDULED][google.ads.admanager.v1.AdBreakStateEnum.AdBreakState.SCHEDULED].
Declaration
public virtual Task<AdBreak> UpdateAdBreak(UpdateAdBreakRequest request, ServerCallContext context)
Parameters
| Type | Name | Description |
|---|---|---|
| UpdateAdBreakRequest | request | The request received from the client. |
| ServerCallContext | context | The context of the server-side call handler being invoked. |
Returns
| Type | Description |
|---|---|
| Task<AdBreak> | The response to send back to the client (wrapped by a task). |