Skip to content

Latest commit

 

History

History
250 lines (141 loc) · 7.25 KB

DistributionsApi.md

File metadata and controls

250 lines (141 loc) · 7.25 KB

\DistributionsApi

All URIs are relative to https://api.phrase.com/v2

Method HTTP request Description
DistributionCreate Post /accounts/{account_id}/distributions Create a distribution
DistributionDelete Delete /accounts/{account_id}/distributions/{id} Delete a distribution
DistributionShow Get /accounts/{account_id}/distributions/{id} Get a single distribution
DistributionUpdate Patch /accounts/{account_id}/distributions/{id} Update a distribution
DistributionsList Get /accounts/{account_id}/distributions List distributions

DistributionCreate

Distribution DistributionCreate(ctx, accountId, distributionCreateParameters, optional)

Create a distribution

Create a new distribution.

Required Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
accountId string Account ID
distributionCreateParameters DistributionCreateParameters
optional *DistributionCreateOpts optional parameters nil if no parameters

Optional Parameters

Optional parameters are passed through a pointer to a DistributionCreateOpts struct

Name Type Description Notes

xPhraseAppOTP | optional.String| Two-Factor-Authentication token (optional) |

Return type

Distribution

Authorization

Basic, Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

DistributionDelete

DistributionDelete(ctx, accountId, id, optional)

Delete a distribution

Delete an existing distribution.

Required Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
accountId string Account ID
id string ID
optional *DistributionDeleteOpts optional parameters nil if no parameters

Optional Parameters

Optional parameters are passed through a pointer to a DistributionDeleteOpts struct

Name Type Description Notes

xPhraseAppOTP | optional.String| Two-Factor-Authentication token (optional) |

Return type

(empty response body)

Authorization

Basic, Token

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

DistributionShow

Distribution DistributionShow(ctx, accountId, id, optional)

Get a single distribution

Get details on a single distribution.

Required Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
accountId string Account ID
id string ID
optional *DistributionShowOpts optional parameters nil if no parameters

Optional Parameters

Optional parameters are passed through a pointer to a DistributionShowOpts struct

Name Type Description Notes

xPhraseAppOTP | optional.String| Two-Factor-Authentication token (optional) |

Return type

Distribution

Authorization

Basic, Token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

DistributionUpdate

Distribution DistributionUpdate(ctx, accountId, id, distributionUpdateParameters, optional)

Update a distribution

Update an existing distribution.

Required Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
accountId string Account ID
id string ID
distributionUpdateParameters DistributionUpdateParameters
optional *DistributionUpdateOpts optional parameters nil if no parameters

Optional Parameters

Optional parameters are passed through a pointer to a DistributionUpdateOpts struct

Name Type Description Notes

xPhraseAppOTP | optional.String| Two-Factor-Authentication token (optional) |

Return type

Distribution

Authorization

Basic, Token

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

DistributionsList

[]DistributionPreview DistributionsList(ctx, accountId, optional)

List distributions

List all distributions for the given account.

Required Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
accountId string Account ID
optional *DistributionsListOpts optional parameters nil if no parameters

Optional Parameters

Optional parameters are passed through a pointer to a DistributionsListOpts struct

Name Type Description Notes

xPhraseAppOTP | optional.String| Two-Factor-Authentication token (optional) | page | optional.Int32| Page number | perPage | optional.Int32| Limit on the number of objects to be returned, between 1 and 100. 25 by default |

Return type

[]DistributionPreview

Authorization

Basic, Token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]