Skip to content

Commit

Permalink
Update for rebrand
Browse files Browse the repository at this point in the history
  • Loading branch information
Majored committed Aug 9, 2022
1 parent 329bdc1 commit 2fd6e5d
Show file tree
Hide file tree
Showing 17 changed files with 26 additions and 26 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# php-mcm-api-wrapper
[![GitHub license](https://img.shields.io/badge/license-MIT-007ec6)](https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
# BuiltByBit PHP API Wrapper
[![GitHub license](https://img.shields.io/badge/license-MIT-007ec6)](https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

A PHP wrapper for MC-Market's [HTTP API](https://www.mc-market.org/wiki/ultimate-api/).
A PHP wrapper for BuiltByBit's [HTTP API](https://builtbybit.com/wiki/ultimate-api/).

- Full coverage of the API.
- Type hinting used for IDE autocomplete & readability.
Expand All @@ -10,13 +10,13 @@ A PHP wrapper for MC-Market's [HTTP API](https://www.mc-market.org/wiki/ultimate

## Usage

An extensive list of [examples](https://github.com/Majored/php-mcm-api-wrapper/tree/main/examples) can be found under the `/examples` directory.
An extensive list of [examples](https://github.com/Majored/php-bbb-api-wrapper/tree/main/examples) can be found under the `/examples` directory.

```PHP
<?php
require __DIR__ . "/../src/APIWrapper.php";

$token = new APIToken(TokenType::PRIVATE, "Find @ https://www.mc-market.org/account/api");
$token = new APIToken(TokenType::PRIVATE, "Find @ https://builtbybit.com/account/api");
$wrapper = new APIWrapper();

if ($error = $wrapper->initialise($token)->getError()) {
Expand All @@ -27,6 +27,6 @@ echo $wrapper->members()->fetch(87939)->getData()["username"];
```

## Issues & Support
Whether you're wanting to report a bug you've come across during use of this wrapper or are seeking general help/assistance, please utilise the [issues tracker](https://github.com/Majored/php-mcm-api-wrapper/issues) and tag your issue appropriately during creation.
Whether you're wanting to report a bug you've come across during use of this wrapper or are seeking general help/assistance, please utilise the [issues tracker](https://github.com/Majored/php-bbb-api-wrapper/issues) and tag your issue appropriately during creation.

I try to respond to issues within a reasonable timeframe.
2 changes: 1 addition & 1 deletion examples/index.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

require __DIR__ . "/../src/APIWrapper.php";

Expand Down
4 changes: 2 additions & 2 deletions src/APIResponse.php
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** Represents a parsed response from MC-Market's API. */
/** Represents a parsed response from BuiltByBit's API. */
class APIResponse {
/** @var string A string representing whether this response was successful or not. */
private $result;
Expand Down
2 changes: 1 addition & 1 deletion src/APIToken.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** Stores data about a particular API token. */
class APIToken {
Expand Down
8 changes: 4 additions & 4 deletions src/APIWrapper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

require __DIR__ . "/APIToken.php";
require __DIR__ . "/APIResponse.php";
Expand All @@ -19,10 +19,10 @@
require __DIR__ . "/helpers/Resources/UpdatesHelper.php";
require __DIR__ . "/helpers/Resources/ReviewsHelper.php";

/** The primary class for interactions with MC-Market's API. */
/** The primary class for interactions with BuiltByBit's API. */
class APIWrapper {
/** @var string The base URL of MC-Market's API that we prepend to endpoints. */
const BASE_URL = "https://api.mc-market.org/v1";
/** @var string The base URL of BuiltByBit's API that we prepend to endpoints. */
const BASE_URL = "https://api.builtbybit.com/v1";

/** @var string The complete header line for request bodies (JSON). */
const CONTENT_TYPE_HEADER = "Content-Type: application/json";
Expand Down
2 changes: 1 addition & 1 deletion src/Throttler.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** Stores metadata needed for local request throttling. */
class Throttler {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/AlertsHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for alert-related API endpoints. */
class AlertsHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/ConversationsHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for conversation-related API endpoints. */
class ConversationsHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/MembersHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for member-related API endpoints. */
class MembersHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/ThreadsHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for thread-related API endpoints. */
class ThreadsHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/resources/DownloadsHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for download-related API endpoints. */
class DownloadsHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/resources/LicensesHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for license-related API endpoints. */
class LicensesHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/resources/PurchasesHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for purchase-related API endpoints. */
class PurchasesHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/resources/ResourcesHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for resource-related API endpoints. */
class ResourcesHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/resources/ReviewsHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for review-related API endpoints. */
class ReviewsHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/resources/UpdatesHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for update-related API endpoints. */
class UpdatesHelper {
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/resources/VersionsHelper.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Copyright (c) 2021 Harry [Majored] [[email protected]]
// MIT License (https://github.com/Majored/php-mcm-api-wrapper/blob/main/LICENSE)
// MIT License (https://github.com/Majored/php-bbb-api-wrapper/blob/main/LICENSE)

/** A helper class for version-related API endpoints. */
class VersionsHelper {
Expand Down

0 comments on commit 2fd6e5d

Please sign in to comment.