|
| 1 | +--- |
| 2 | +title: [ENDPOINT_NAME] |
| 3 | +description: Interacting with Moneybird's [ENDPOINT_NAME] API. |
| 4 | +--- |
| 5 | + |
| 6 | +Manage your [ENDPOINT_NAME] in Moneybird. |
| 7 | + |
| 8 | +## Working with [ENDPOINT_NAME] |
| 9 | + |
| 10 | +This section covers how to interact with Moneybird's [ENDPOINT_NAME] API. You can create, retrieve, update, and delete [ENDPOINT_NAME], as well as [MENTION_ANY_SPECIALIZED_FEATURES]. |
| 11 | + |
| 12 | +### Basic Operations |
| 13 | + |
| 14 | +#### Get a [SINGULAR_ENDPOINT_NAME] |
| 15 | + |
| 16 | +Retrieve a [SINGULAR_ENDPOINT_NAME] by its ID. |
| 17 | + |
| 18 | +```php |
| 19 | +$[SINGULAR_ENDPOINT_NAME_LOWERCASE] = $client->[ENDPOINT_NAME_LOWERCASE]()->get('[EXAMPLE_ID]'); |
| 20 | +``` |
| 21 | + |
| 22 | +#### List [ENDPOINT_NAME] |
| 23 | + |
| 24 | +Get a paginated list of [ENDPOINT_NAME]. |
| 25 | + |
| 26 | +```php |
| 27 | +$[ENDPOINT_NAME_LOWERCASE] = $client->[ENDPOINT_NAME_LOWERCASE]()->paginate(); |
| 28 | + |
| 29 | +// Iterate through the pages |
| 30 | +foreach ($[ENDPOINT_NAME_LOWERCASE] as $[SINGULAR_ENDPOINT_NAME_LOWERCASE]) { |
| 31 | + echo $[SINGULAR_ENDPOINT_NAME_LOWERCASE]->[MAIN_PROPERTY]; |
| 32 | +} |
| 33 | +``` |
| 34 | + |
| 35 | +#### Create a [SINGULAR_ENDPOINT_NAME] |
| 36 | + |
| 37 | +Create a new [SINGULAR_ENDPOINT_NAME]. |
| 38 | + |
| 39 | +```php |
| 40 | +$data = [ |
| 41 | + // Include example properties with realistic values |
| 42 | + '[PROPERTY1]' => '[VALUE1]', |
| 43 | + '[PROPERTY2]' => '[VALUE2]', |
| 44 | +]; |
| 45 | + |
| 46 | +$[SINGULAR_ENDPOINT_NAME_LOWERCASE] = $client->[ENDPOINT_NAME_LOWERCASE]()->create($data); |
| 47 | +``` |
| 48 | + |
| 49 | +#### Update a [SINGULAR_ENDPOINT_NAME] |
| 50 | + |
| 51 | +Update an existing [SINGULAR_ENDPOINT_NAME]. |
| 52 | + |
| 53 | +```php |
| 54 | +$updateData = [ |
| 55 | + '[PROPERTY1]' => '[UPDATED_VALUE1]', |
| 56 | +]; |
| 57 | + |
| 58 | +$[SINGULAR_ENDPOINT_NAME_LOWERCASE] = $client->[ENDPOINT_NAME_LOWERCASE]()->update('[EXAMPLE_ID]', $updateData); |
| 59 | +``` |
| 60 | + |
| 61 | +#### Delete a [SINGULAR_ENDPOINT_NAME] |
| 62 | + |
| 63 | +Delete a [SINGULAR_ENDPOINT_NAME]. |
| 64 | + |
| 65 | +```php |
| 66 | +$client->[ENDPOINT_NAME_LOWERCASE]()->delete('[EXAMPLE_ID]'); |
| 67 | +``` |
| 68 | + |
| 69 | +### [SPECIALIZED_FEATURE_1] |
| 70 | + |
| 71 | +[DESCRIBE_SPECIALIZED_FEATURE_1] |
| 72 | + |
| 73 | +#### [SPECIALIZED_METHOD_1] |
| 74 | + |
| 75 | +```php |
| 76 | +[EXAMPLE_CODE_FOR_SPECIALIZED_METHOD_1] |
| 77 | +``` |
| 78 | + |
| 79 | +### [SPECIALIZED_FEATURE_2] |
| 80 | + |
| 81 | +[DESCRIBE_SPECIALIZED_FEATURE_2] |
| 82 | + |
| 83 | +#### [SPECIALIZED_METHOD_2] |
| 84 | + |
| 85 | +```php |
| 86 | +[EXAMPLE_CODE_FOR_SPECIALIZED_METHOD_2] |
| 87 | +``` |
| 88 | + |
| 89 | +## [SINGULAR_ENDPOINT_NAME] Properties |
| 90 | + |
| 91 | +When working with [ENDPOINT_NAME_LOWERCASE], you'll have access to the following properties: |
| 92 | + |
| 93 | +| Property | Type | Description | |
| 94 | +|----------|------|-------------| |
| 95 | +| id | string | Unique identifier | |
| 96 | +| [PROPERTY1] | [TYPE1] | [DESCRIPTION1] | |
| 97 | +| [PROPERTY2] | [TYPE2] | [DESCRIPTION2] | |
| 98 | +| [PROPERTY3] | [TYPE3] | [DESCRIPTION3] | |
| 99 | +| [CONTINUE_WITH_ALL_RELEVANT_PROPERTIES] | | | |
| 100 | + |
| 101 | +> **Note:** See the [official API reference](https://developer.moneybird.com/api/[ENDPOINT_NAME_LOWERCASE]/#[ENDPOINT_NAME_LOWERCASE]-object) for the complete list of available properties. |
| 102 | +
|
| 103 | +## Further reading |
| 104 | + |
| 105 | +- Read [the full API reference](https://developer.moneybird.com/api/[ENDPOINT_NAME_LOWERCASE]/) in the Moneybird developer docs |
| 106 | + |
| 107 | +<!-- |
| 108 | +Style guidelines: |
| 109 | +1. Focus on functionality rather than implementation details |
| 110 | +2. Use practical examples with realistic values |
| 111 | +3. Don't mention class names or implementation details |
| 112 | +4. Format all code examples in PHP |
| 113 | +5. Include a properties table with types and descriptions |
| 114 | +6. Keep explanations concise and user-focused |
| 115 | +7. Group related operations into logical sections |
| 116 | +8. Include any specialized methods specific to this endpoint |
| 117 | +9. Use consistent formatting and terminology throughout |
| 118 | +--> |
0 commit comments